--- source: crates/biome_js_analyze/tests/spec_tests.rs expression: invalidClass.js --- # Input ```jsx class c {} class camelCase {} export default class default_class {} const x = class CLASS_EXPRESSION {} class Unknown_Style {} ``` # Diagnostics ``` invalidClass.js:1:7 lint/style/useNamingConvention FIXABLE ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ ! This class name should be in PascalCase. > 1 │ class c {} │ ^ 2 │ 3 │ class camelCase {} i The name could be renamed to `C`. i Safe fix: Rename this symbol in PascalCase. 1 │ - class·c·{} 1 │ + class·C·{} 2 2 │ 3 3 │ class camelCase {} ``` ``` invalidClass.js:3:7 lint/style/useNamingConvention FIXABLE ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ ! This class name should be in PascalCase. 1 │ class c {} 2 │ > 3 │ class camelCase {} │ ^^^^^^^^^ 4 │ 5 │ export default class default_class {} i The name could be renamed to `CamelCase`. i Safe fix: Rename this symbol in PascalCase. 1 1 │ class c {} 2 2 │ 3 │ - class·camelCase·{} 3 │ + class·CamelCase·{} 4 4 │ 5 5 │ export default class default_class {} ``` ``` invalidClass.js:5:22 lint/style/useNamingConvention ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ ! This class name should be in PascalCase. 3 │ class camelCase {} 4 │ > 5 │ export default class default_class {} │ ^^^^^^^^^^^^^ 6 │ 7 │ const x = class CLASS_EXPRESSION {} i The name could be renamed to `DefaultClass`. ``` ``` invalidClass.js:7:17 lint/style/useNamingConvention FIXABLE ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ ! This class name should be in PascalCase. 5 │ export default class default_class {} 6 │ > 7 │ const x = class CLASS_EXPRESSION {} │ ^^^^^^^^^^^^^^^^ 8 │ 9 │ class Unknown_Style {} i The name could be renamed to `ClassExpression`. i Safe fix: Rename this symbol in PascalCase. 5 5 │ export default class default_class {} 6 6 │ 7 │ - const·x·=·class·CLASS_EXPRESSION·{} 7 │ + const·x·=·class·ClassExpression·{} 8 8 │ 9 9 │ class Unknown_Style {} ``` ``` invalidClass.js:9:7 lint/style/useNamingConvention FIXABLE ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ ! This class name should be in PascalCase. 7 │ const x = class CLASS_EXPRESSION {} 8 │ > 9 │ class Unknown_Style {} │ ^^^^^^^^^^^^^ i The name could be renamed to `UnknownStyle`. i Safe fix: Rename this symbol in PascalCase. 7 7 │ const x = class CLASS_EXPRESSION {} 8 8 │ 9 │ - class·Unknown_Style·{} 9 │ + class·UnknownStyle·{} ```