Camel Case vs Snake Case vs Kebab Case
Published at May 25, 2023
Camel Case
I used to write everything in this style, but it is kind of ugly.
wordWord
Snake Case
I prefer this style for variables, because it is easier to read than camel case. And you have to use it for constants, so that you don’t end up with something like WORDWORD
.
word_word
WORD_WORD
Kebab Case
I prefer this style for filenames.
word-word
WORD-WORD
Sometimes I mix all 3 of them
Example for naming projects:
MainTopic_Project-Name