Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 
avatar of wvdhaute

wvdhaute

wvdhaute has asked 1 questions and find answers to 3 problems.

Stats

38
EtPoint
3
Vote count
1
questions
3
answers

About

Clean code and the KISS principle

If a chunk of code cannot be understood without reading it 5 times, this should be considered bad code and refactored.

TDD

Should be used from a pragmatic approach. Not all chunks of code should be developed from a unit test. Only use this when the logic is "complex" enough for mistakes to be made but never be arrogant and question yourself on those decisions.

Broken windows theory

This kind of relates to clean code as I firmly believe that once dirty code intrudes your codebase, this will often lead to other developers not making enough effort to write clean code around that dirt code which will in the end spread out to your whole codebase.

Seperation of concerns and domain driven design

This leads to simpler code, safer code, more testable code and more maintainable code.

Commit often, small victories, divide and conquer

If you haven't made a code commit by noon, you are probably taking on too much at once. Always go for small victories as this will lead to a more fulfilling development process and better, simpler and cleaner code.

Agile

Continuous delivery/deployment will lead to software that can be more reliably released at all time . Daily standups can lead to interesting coffee break/lunch time discussions but should be kept to the point, not just "I've added this and that". Regularly, time should be allocated to reflect, should some code be cleaned up, can we improve a project from things learned in another project, are there certain "annoyances" in the development cycle that can be improved, ...

I am a realist that above principles will not always be possible to follow as we don't live in a perfect world and sometimes deadlines just have to made. Yet I do believe that if they are used from the start, at all times a best effort is done and periodically time is allocated to clean up, this will lead to faster development cycles, less bugs and better maintainable code.