DEV Community

Discussion on: A Minimalist's Guide to Software Development: Less Code, More Elegance

Collapse
 
lnahrf profile image
Lev Nahar

Nice post, it’s a good read! This approach is okay as long as you don’t compromise integrity (e.g. I’ll just use this magic function and hope it’s efficient). Writing clean code has nothing to do with minimalism, in my opinion. A function can run loops and manipulate bytes and still be considered “clean code”. Wrapping logic with another layer of abstraction usually causes more trouble than it’s worth (although sometimes useful).

There is also the issue of over-generity where one function (or logic) handles a lot of cases and the tiniest change to one of them makes the whole application collapse (I have seen this so many times) - all for the sake of “generic” or “clean code”.

From my experience, most of the time clean code is the opposite - the explicit call to a very niche, isolated part of the code, that works as independently as possible even at the compromise of efficiency.

Your point about not having dependencies I completely agree with, but when wrapping everything in another layer of abstraction it is hard to maintain.

Thanks for sharing!

Collapse
 
vedangit profile image
Vedangi Thokal

Certainly agree with what you said here. Thank you for your insights!