Next.js Discord

Discord Forum

Naming conventions, Pascal, Kebab, Camel ??

Unanswered
Barbary Lion posted this in #help-forum
Open in Discord
Barbary LionOP
What is your preferred (or the Next/React 'correct') naming convention for:

1) File names
2) Component names
3) Anything else?

3 Replies

@Barbary Lion What is your preferred (or the Next/React 'correct') naming convention for: 1) File names 2) Component names 3) Anything else?
1. this-case
2. ThisCase
3. Standard js casing (thisCase for variables, ThisCase for types and classes, THIS_CASE for constants)
The reason why I choose this-case for file names is because there are case insensitive systems and there are case sensitive systems and managing casing between them is a pain if uppercase characters are involved
Barbary LionOP
Cool, didn't know what was the best to use for files names, so that sells me on the idea of hyphenated