survivejs/maintenance-book

Code quality ideas

rstegg opened this issue · 2 comments

Code quality, I want to say should have some layout like:

  • Modularity: writing code as standalone pieces towards a bigger puzzle

  • Naming: how to write good naming by following simple conventions

  • Consistency: consistent code is easier to read

  • "Cost factors"?: are you planing to expand your team? focus on readability and testability. planning on writing a proof-of-concept/side project? focus on the modularity so you can use your code later & aren't wasting your time when you write a side project.

"Cost factors" should stress that readability and testability being the desired use case
because sometimes modular code is just for sanity and only is useful if you plan to reuse or build upon the code. I'd say modularity is more of a best practice than a fundamental in regards to code quality, though it is important.

Thoughts?

All these are good but of of the scope of a book about tools. And there are many good books that covers these questions like Code Complete or Clean Code.

Perhaps the best way to handle this would be to have small appendix pointing to books that discuss the topic in greater detail. It's enough to cover the topic from JS point of view here.