Hacker News new | ask | show | jobs
by ohthatsnotright 583 days ago
Often what is one developers "best practice" is another's "anti-pattern" because a lot of this is just arbitrary.
4 comments

If it is arbitrary, it’s “standard practice”.
Which still has immense value.

It's standard practice to install outlets with NEMA connectors in North American buildings. Sure, you could technically swap those out with a more optimal connector that is "better" (one that prevents electricity from flowing while the plug is partially exposed, for example), but using the standard practice is best practice for human-shaped reasons that are often not apparent to early-career engineers.

I’m a bit confused with the analogy here. Would the non NEMA outlets work with my existing things or is the implication that they wouldn’t?
They wouldn't, but about half of the developers commenting here would do the equivalent of switching from NEMA to something else on the grounds that the something else is better.
There’s usually nothing “best” about it.
There are many like that. Every practice is a trade off.

However, there are many where the cost/benefit ratio is so large that you can default to "you should just do this".

I dont think Id ever look at a company that e.g. had no CI or versioning for a large project for instance and think "they might have had a good reason for this". They didnt.

Hot take, the biggest advantage to following «best practices» is that when someone else stumbles over your project, they can follow along more easily