I am a big believer in the YAGNI (You aren’t gonna need it) principle. But it applies to features, not coding practices. It is more of a way to say: Code the MVP (minimal viable product) firs…
Hiding the code behind other functions does not make it easier to read, only means you need to jump around a lot in order to understand what it is doing which IMO makes things harder to read.
Exactly. That’s my gripe with most JS and PHP frameworks, some people just don’t work that way. Thanks, now i have to grok 70% of the codebase to understand what i need to change to implement simple feature request X.
But on the other hand, limiting the scope of functions is a must. Superfunctions are a plague.
Exactly. That’s my gripe with most JS and PHP frameworks, some people just don’t work that way. Thanks, now i have to grok 70% of the codebase to understand what i need to change to implement simple feature request X.
But on the other hand, limiting the scope of functions is a must. Superfunctions are a plague.