5 ms·
The article is actually good. The criticisms of DRY here are valid! For criticism 1, I had a coworker once say something that resonated with me: "Just because
by amw-zero 4y ago
The article is actually good. The criticisms of DRY here are valid! For criticism 1, I had a coworker once say something that resonated with me:
"Just because two things are the same right now doesn't mean they _should_ be the same."
So that criticism is totally valid - DRY has to be applied only when things _should_ be the same, and that can actually be hard to identify.
That being said, of course the title of the article is bad and not accurate. DRY is essential. I don't think there's many people that actually argue against it. If you have a piece of business logic that's essential to the business and it influences other pieces of logic, they all have to refer to the same definition. Repeating it is bad for everyone - users will see inconsistent behavior, and devs will have to "remember" (read: never actually remember) to update important logic in multiple places. Important things should have a single source of truth. That seems inarguable to me.
It can be hard to find a design that actually achieves that. That's not DRY's fault.
- HelloNurse 4y agoNo, this article isn't good because it discusses alternative options within the boundaries of seriously wrong premises (write nonsensical hardcoded recipes "right"), and unsurprisingly all the options are bad.