Skip to main content

configuration

Enable only the full Stylelint configuration-authoring workflow.

Use this preset when you want to lint stylelint.config.* and .stylelintrc.* files for config hygiene, but you do not want the stylesheet bridge, source CSS linting, or Stylelint autofix bridging enabled in the same preset.

Flat config exampleโ€‹

import stylelint2 from "eslint-plugin-stylelint-2";

export default [
stylelint2.configs.configuration,
];

Legacy alias: stylelint2.configs.configs remains supported for backwards compatibility.

What this preset includesโ€‹

Configuration-focused policy rules only. See the canonical rules table below for the exact preset contents.

What this preset does not includeโ€‹

  • No CSS stylelint-2/stylelint bridge rule
  • No stylesheet linting for **/*.css
  • No Stylelint autofix bridge for source CSS files

Rules in this presetโ€‹

For the exhaustive generated rule matrix, see Presets overview.

RuleFix
prefer-stylelint-cache๐Ÿ”ง
disallow-stylelint-default-severity๐Ÿ”ง
prefer-stylelint-fix๐Ÿ”ง
prefer-stylelint-formatterโ€”
disallow-stylelint-ignore-disables๐Ÿ”ง
disallow-stylelint-ignore-files๐Ÿ”ง
prefer-stylelint-define-config๐Ÿ”ง
prefer-stylelint-report-descriptionless-disables๐Ÿ”ง
prefer-stylelint-report-invalid-scope-disables๐Ÿ”ง
prefer-stylelint-report-needless-disables๐Ÿ”ง
prefer-stylelint-report-unscoped-disables๐Ÿ”ง