notes on Clean Code - Meaningful Names chapter
02 Oct 2014Names are the essence of source code - hence need to choose them with great care.
- Create names which show the intention, how the named thing should be used.
- Avoid confusioni: don’t use names using many similar words with tiny differences.
- Names should be easy to pronounce.
- Don’t make them clever/cute/funny - it is easy to forget what they actually mean.
- Use a single name per concept and make it consistent across the code base.
- Use the language of domain in which the project is in.
- Add meaningful context.