media-feature-name-no-vendor-prefix
What it does
Section titled “What it does”Reports a vendor-prefixed device-pixel-ratio media feature (-webkit-min-device-pixel-ratio).
Why it matters
Section titled “Why it matters”The standard media feature is resolution, and the prefixed names are supported only by old engines. The standard one works in every current browser.
To fix, use min-resolution: 2dppx.
Example
Section titled “Example”...@media (-webkit-min-device-pixel-ratio: 2) {}...Configuration
Section titled “Configuration”css: lint: rules: media-feature-name-no-vendor-prefix: level: warn # off (default), warn, error options: ignore: []less: lint: rules: media-feature-name-no-vendor-prefix: level: warn # off (default), warn, error options: ignore: []scss: lint: rules: media-feature-name-no-vendor-prefix: level: warn # off (default), warn, error options: ignore: []| Option | Type | Default | Description |
|---|---|---|---|
ignore |
list | [] |
Names left out: names, or /regex/. |
Enabled by the presets: css/stylelint-standard.
Suppress one line with sudsy-disable-next-line media-feature-name-no-vendor-prefix 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 | media-feature-name-no-vendor-prefix |
full |