Skip to main content

stylelintOnly

Enable only the stylesheet-facing Stylelint bridge workflow.

This preset is the clearest choice when you want Stylelint diagnostics and autofixes to flow through ESLint, but you do not want any Stylelint config-authoring rules in the same preset.

Flat config exampleโ€‹

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

export default [
stylelint2.configs.stylelintOnly,
];

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

What this preset includesโ€‹

What this preset does not includeโ€‹

  • Configuration-authoring policy rules (require-*, disallow-*, sort-*)
  • Operational policy rules like prefer-stylelint-cache and reporting preferences

Rules in this presetโ€‹

RuleFix
stylelint๐Ÿ”ง