Drew DeVault 3/9/2023

When to comment that code

Read Original

The article presents a developer's perspective on code commenting, advocating for fewer but more meaningful comments. It argues that clear function names, well-chosen types, and module structure can convey much of the information typically placed in comments. Using a concrete code example, it distinguishes between documentation for API consumers and internal explanatory notes, emphasizing that code should be written to be self-documenting where possible.

When to comment that code

Comments

No comments yet

Be the first to share your thoughts!

Browser Extension

Get instant access to AllDevBlogs from your browser

Top of the Week