Skip to main content

useCamelCase (since v0.8.0)

Enforce camel case naming convention.

Examples

Invalid

let snake_case;
warning[js/useCamelCase]: Prefer symbols names in camel case.
   js/useCamelCase.js:1:5
  
1  let snake_case;
       ----------

Safe fix: Rename this symbol to camel case
    | @@ -1 +1 @@
0   | - let snake_case;
  0 | + let snakeCase;

let PascalCase;
warning[js/useCamelCase]: Prefer symbols names in camel case.
   js/useCamelCase.js:1:5
  
1  let PascalCase;
       ----------

Safe fix: Rename this symbol to camel case
    | @@ -1 +1 @@
0   | - let PascalCase;
  0 | + let pascalCase;

Valid

let camelCase;