Home Naming Conventions in JavaScript

Variable and Function Names

Give variables and functions descriptive names, such as firstName, homeworkScore, or getAverageTemperature.

Avoid single-letter variable names like xor c, except for loop variables like i.

Letter-Casing and Special Characters

Name variables and functions with camel-casing likeThis, name classes with Pascal casing LikeThis, and name unchanging "constant" variables in all-uppercase LIKE_THIS. Variables and functions should never include "-" or start with numbers in JavaScript.