Clean Code

Personal GitHub site

Clean Code

While reading Clean Code: A Handbook of Agile Software Craftsmanship by Robert C. Martin, A.K.A. “Uncle Bob”, a lot of points made were very relatable. I decided to create these notes to keep a summary of the - for me - most important things to keep in mind.

I try to link idioms, principles, and other constructs to the Refactoring and Design Patterns sections of the Refactoring Guru website. This is a very handy site for finding patterns, code smells, and more!

Why clean code

Why would you want code to be clean? For me, it’s mostly because:

How to keep code clean

The following will only be a subset of the entire “ruleset” described in the book. For a full list of the smells and heuristics, see the table (the numbering and names match both below and the book).

Meaningful Names

Functions

Comments

Formatting

Objects and Data Structures

Error Handling

Boundaries

Unit Tests

Classes

Systems