function-name-case
What it does
Section titled “What it does”Reports a function name with capitals (RGB()). Names such as translateX that are written in camel case in the specification keep theirs.
Why it matters
Section titled “Why it matters”CSS reads function names without regard to case, so capitals add spellings of the same name. A file that writes them in lowercase only is easier to search and read.
Example
Section titled “Example”... width: calc(-1px + 2px);... width: CALC(1px + 2px);... background: linear-gradient(to top, red, blue); background: linear-gradient(45deg, red, blue); background: -webkit-linear-gradient(top, red, blue); transform: translateX(1px) ROTATE(1deg);}Configuration
Section titled “Configuration”css: lint: rules: function-name-case: warn # off (default), warn, errorless: lint: rules: function-name-case: warn # off (default), warn, errorscss: lint: rules: function-name-case: warn # off (default), warn, errorEnabled by the presets: css/stylelint-standard.
Suppress one line with sudsy-disable-next-line function-name-case in a comment of the file’s language.
Upstream equivalents
Section titled “Upstream equivalents”The same check in other tools; Sudsy reports what each upstream rule reports.
| Tool | Rule | Match |
|---|---|---|
| stylelint | function-name-case |
full |