Skip to content

Files

Latest commit

 

History

History
58 lines (35 loc) · 748 Bytes

Naming-VariableNumber.md

File metadata and controls

58 lines (35 loc) · 748 Bytes

Pattern: Invalid style for variable number

Issue: -

Description

This rule makes sure that all numbered variables use the configured style for their numbering.

Examples

"EnforcedStyle => 'snake_case'"

# bad

variable1 = 1

# good

variable_1 = 1
"EnforcedStyle => 'normalcase'"

# bad

variable_1 = 1

# good

variable1 = 1
"EnforcedStyle => 'non_integer'"

#bad

variable1 = 1

variable_1 = 1

#good

variableone = 1

variable_one = 1

Default configuration

Attribute Value
EnforcedStyle normalcase
SupportedStyles snake_case, normalcase, non_integer

Further Reading