Created
January 7, 2016 13:38
-
-
Save yannbertrand/54d32865519cbd399f45 to your computer and use it in GitHub Desktop.
Some advices to apply good names for your programming entities
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
See http://fr.slideshare.net/pirhilton/how-to-name-things-the-hardest-problem-in-programming by @hilton | |
Summary of naming things badly : | |
- meaningless: foo | |
- too general: data | |
- too short: a | |
- too long: text_correction_by_editor | |
- abbreviated: acc (id is the only acceptable abbreviation) | |
- vague: InvoiceManager | |
- wrong: order | |
- just not funny: startCamel | |
Replace vague words with more specific synonyms: | |
- Manager/do | |
- Object/execute | |
- Data/perform | |
- Thing/operate | |
- Info/manage | |
- Amount/handle | |
- Details/get | |
Never stop learning new vocabulary ! |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment