I assume this is not original at all at this point - but (extreme) DRY is not a good practice. My experience is that a bit of copying yourself and your colleagues in the code base often make maintenance of the code base easier.
@honey_ohs๐ฅทprofilefollowSoftware engineer. [Reluctant] Salesforce dev. Salesforceโs biggest hater.
stephenlf.devstephenlf.devImportant Thingsreplied to@asmund๐ฅทprofilefollowFather, getting older every day, technologist, enterprise architect @ work, like to explore tech. Like to keep it simple and work in the shell, write in vim, prefer Debian if I have the choice. Plays saxophone and clarinet. Enjoy motorcycle riding, photography, hiking. Christian.:
Many have adopted the term WET (write everything twice)
Uncompromising adherence to DRY.
First copy-paste? Fine by me. Second? I'll still let it slide. Third? OK, now let's think about finding a suitable refactor.
Getters and setters for everything. Certainly, if you want an object to be doing more than just getting and setting a value right now, get them in there!
Planning to add functionality later without breaking code? Stop it! That should break code! If I'm consuming a library and have been using this setter method for 2 years, I don't want it to suddenly introduce brand new validation, caching, or logging behavior!
Are getters and setters on everything even considered a good practice? To me it screams junior developer who hasnโt yet fully understood encapsulation and abstraction โ if youโre just exposing getters and setters as the interface then what is the class/module/etc providing beyond what a standard variable doesโฆ?
Brikka.
Someone on HN mentioned it as great design. I looked it up and bought it after a while. It's been such a delight. Even the occasional brew gone wrong adds to the experience.
v60 is also nice when I need it to slow down or be the experience a bit meditative. But Chinese tea is the best for that.
@thechelsukprofilefollowCurrently in remission from ME/CFS after 3+ years. Occasional software engineering leader, app developer, blogger, zwifter, and just being online.wrote:
@derblitzmann๐profilefollow10+ years Seattle based software engineer.replied to@thechelsukprofilefollowCurrently in remission from ME/CFS after 3+ years. Occasional software engineering leader, app developer, blogger, zwifter, and just being online.: