An Interest In:
Web News this Week
- April 3, 2024
- April 2, 2024
- April 1, 2024
- March 31, 2024
- March 30, 2024
- March 29, 2024
- March 28, 2024
November 12, 2020 06:52 pm GMT
Original Link: https://dev.to/exceedteam/tips-for-maintainable-code-3ike
Tips I've learned over 10 years for maintainability of my code
I've been writing code for over 10 years now, and although I've been doing more management lately, at my peak I was able to write 500+ lines of well-performing code a day. Here are the principles that helped me with this:
- Don't over-generalize
- Don't optimize your code in advance
- Name and group everything that happens correctly
- Don't mix algorithms and other technologically complex pieces of code with business logic
- Don't use any advanced features of any language
- It is worth throwing all OOP out of your head
- Use as many asserts, logs and other methods to catch unplanned system state as early as possible
- Every extra line of code is evil
Here I placed just names of my mistakes, but if you are interested here the full version with each point explanations
Original Link: https://dev.to/exceedteam/tips-for-maintainable-code-3ike
Share this article:
Tweet
View Full Article
Dev To
An online community for sharing and discovering great ideas, having debates, and making friendsMore About this Source Visit Dev To