How to write clean code units (functions and methods)
Code units at the edges of your application should be small, independent and only do one thing…. » DEV Community | dev.to
Code units at the edges of your application should be small, independent and only do one thing…. » DEV Community | dev.to
When it comes to writing code, I aim to write simple code. What Bob Martin calls clean code. What oth… » DEV Community | dev.to
What has clean code ever done for us? » DEV Community | dev.to
I’ve been writing code for 20 years. During that time I’ve worked with 17 teams coding different languages to build hundreds of projects. These include everything from a simple blog site, to APIs supporting 3,000 requests/second, to top selling apps. From these experiences, combined with the books I’ve read, it’s become apparent to me what matters most in code: readability. » Jason McCreary | jason.pureconcepts.net
What would ”nice looking”—or ”beautiful”, for that matter—actually mean when referring to source code? I asked some programmer friends what they thought that meant. Their answers were obvious, but still worth stating: Code should be locally coherent and single-functioned: One function should do exactly one thing. It should be clear about what it’s doing. Local code should explain, or at least hint at the overall system design. Code should be self-documenting. Comments should be avoided whenever possible. Comments duplicate work when both writing and reading code. If you need to comment something to make it understandable it should probably be rewritten. » Shawn McGrath | kotaku.com