npm / stylelint
stylelint
What changed in stylelint 16 to 17, from its official release notes, upgrade guides and advisories. Sources checked 2026-10-17.
11 breaking1 deprecations24 new APIs and options22 performance2 behavior and defaults2 tooling70 fixes and other
See which of these apply to your code, ranked, in your agent:
npx @unstale/cli initstylelint 17125 changes
Breaking changes 11
The CommonJS Node.js API was removed.
The rule now behaves consistently for vendor prefixes.
The default
fixmode changed tostrict.The GitHub formatter was removed.
Rules now behave consistently for vendor prefixes and case.
The rule's behavior changed for standard CSS nesting.
The
outputproperty was removed from the resolved object returned by the Node.js API.Support for Node.js versions earlier than 20.19.0 was removed.
The
resolveNestedSelectorsoption was removed.The
checkContextFunctionalPseudoClassesoption was removed.The rule's behavior changed for standard CSS nesting.
Deprecations 1
The rule's *syntax options are deprecated.
New APIs and options 23
Adds the ignoreFunctions option to color-named.
Adds the ignoreFunctions option to color-no-hex.
Adds the selector-no-unmatchable rule.
Adds autofixed to the result object.
Adds a loader property to experimental referenceFiles for cases where the order of appearance in reference styles matters.
Added the selector-no-invalid rule.
Added the unit-layout-mappings rule to enforce logical or physical properties, units and keywords.
Added the value-keyword-layout-mappings rule to enforce logical or physical properties, units and keywords.
Adds an experimental Node.js API option for cancellation support.
Adds maxWarnings to the configuration object.
Adds an experimental configuration property that makes the no-unknown-animations, no-unknown-custom-media and no-unknown-custom-properties rules more useful.
Adds the languageOptions.directionality configuration property.
Adds the property-layout-mappings rule.
Adds the relative-selector-nesting-notation rule.
Adds the selector-no-deprecated rule.
Supports extending units in languageOptions; the extended units apply to rules such as declaration-property-value-no-unknown.
Adds the
ignoreMediaFeatureNameValuesoption.Adds the ignoreAtRules option, defaulting to an empty array, to let developers ignore at-rules.
Adds the ignoreMediaFeatureNames option, defaulting to an empty array, to let developers ignore media feature names.
Adds the display-notation rule. The release notes say its options have not yet been chosen for the standard config.
The
exceptoption now acceptsafter-block.The
exceptoption now acceptsafter-block.The rule now supports the
ignoreSelectorssecondary option.
Performance 22
Improved the performance of getting module paths.
TIMING is dynamically imported only when used, improving performance.
Improves the performance of *-empty-line-before rules.
Improves the performance of no-irregular-whitespace.
Improves the performance of selector cloning rules.
The rule's performance was improved.
The rule's performance was improved.
Improves the performance of declaration-property-value-no-unknown.
The rule's performance was improved.
Performance of
*-listrules was improved.The rule's performance was improved.
Performance of
*-notationrules was improved.Rule sequencing performance was improved.
Performance of
selector-max-*rules was improved.The rule's performance was improved.
The rule's performance was improved.
The rule's performance was improved.
The rule's performance was improved.
Performance of config augmentation and module imports was fixed, contributing to faster execution and lower memory use on larger codebases.
Performance of config override matching was fixed, contributing to faster execution and lower memory use on larger codebases.
Performance of config resolution was fixed, contributing to faster execution and lower memory use on larger codebases.
Performance of rule resolution was fixed, contributing to faster execution and lower memory use on larger codebases.
Behavior and default changes 2
Syntax rules now account for standard CSS nesting and modern functional pseudo-classes.
Semantic rules now account for standard CSS nesting.
Tooling 2
Version 1.0.0 is available to help with first-time Stylelint setup.
The Stylelint Language Server has its first release.
Fixes and other changes 64
Fixes false negatives for uppercase property names.
Fixes false negatives for uppercase units.
Fixes false positives for anchor positioning.
Fixes autofix behavior for the font shorthand.
Fixes false positives for interpolated inline expressions.
Fixes false negatives for pseudo-elements, combinators and nested :has().
Autofix no longer produces an invalid background shorthand when background-size is present.
The quiet option now suppresses report* warning reports.
Fixed the reported range of unknown rules.
Fixed false positives for shared-line comments when
except: ["after-single-line-comment"]is configured.Fixed false negatives for unspaced + and - operators following a * or / operator.
Fixes false negatives for interleaved non-consecutive duplicate properties when ignore is set to consecutive-duplicates(-*).
Fixes false positives for nested selectors.
Fixes false positives for install.
Fixed range reporting when using comments.
Fixed false negatives for custom properties defined in reference files.
Fixes false positives for
caption-side.Fixed
node_modulesignore behavior forcodeFilenamepaths containing a dot-prefixed directory.Fixed the rule's range for contiguous redundant longhand properties.
Fixed inconsistent error messages when a module is not found.
Fixed false negatives for property names in declaration values.
Fixed false positives for @page properties.
Fixed false positives for nested webkit-scrollbar parts.
Fixed a regression that caused ConfigurationError for custom syntaxes.
Fixed autofix for
page-break-*: always.Fixed false positives for
::part().Avoids false positives when URLs have modifiers.
The CLI flag now hides internal properties.
Problem messages are clearer by removing filler words and leading with the problem.
Avoids false positives for
:has().Fixes missing ruleMetadata when linting multiple files with overrides.
node_modulesis now ignored whencodeFilenameis used in the Node.js API.Fixes TS7016 for imported
css-treetypes.The rule no longer reports false positives for function arguments.
The rule no longer reports false positives for
calc-size()containing thesizekeyword.The rule no longer misses equivalent compound selectors.
The rule no longer misses equivalent compound selectors.
The rule no longer reports false positives for
@mixinand@scope.The rule no longer misses cases involving
types.Fixes false negatives for at-rule descriptors.
Fixes false positives for corner-shape.
Fixes false positives for double-slashed properties.
The rule no longer misses math functions inside non-math functions.
The rule no longer reports false positives for
calc()with mixed operations.The rule now reports correct ranges for multiple math functions.
The rule no longer reports false positives for a mix of tabs and spaces.
Fixed false negatives for math functions.
Fixed false negatives for matching escaped selectors.
Fixed false negatives for layers with blocks.
Fixed resolution of configs, plugins, processors, and custom syntaxes in Yarn PnP environments.
Fixes TypeScript errors involving GlobbyOptions.
Fixes false negatives and positives for relative colors.
Fixes false negatives for relative colors.
Fixed false positives for declarations within feature-value-blocks.
Fixed false negatives for short and long combinations.
Fixed Windows drive letter casing inconsistencies when matching patterns against file paths.
Fixed false positives for namespaced dollar variables and range context queries.
Fixed false positives for CSS-in-JS.
Fixed false negatives for embedded blocks.
Rules now behave consistently for their
ignore*secondary options.The handling of provided position arguments is now consistent and predictable.
Fixed false negatives for
:is/where().Fixed false positives for MathML 4 tags.
CLI help now includes TypeScript config files.
stylelint 167 changes
New APIs and options 1
Supports a function export for customSyntax.
Fixes and other changes 6
Fixes false positives for
@function.Fixes false positives for
attr(),if()and custom functions.Fixes false positives when URLs require quoting.
Fixes false positives for the latest CSS specifications by integrating CSS syntax patches.
Fixes false positives for
::scroll-button().Fixes false positives for style query in the if() function.