Skip to main content

Overview

eslint-plugin-stylelint-2 is built for teams that want Stylelint and ESLint to cooperate cleanly.

  1. Bridge Stylelint into ESLint so style diagnostics and autofixes can flow through your existing ESLint pipeline.
  2. Enforce maintainable Stylelint config authoring so your Stylelint configuration stays predictable, reviewable, and automation-friendly.

If you only care about bridge behavior, start with:

If you also want strict configuration hygiene, start with:

How this rules documentation is organizedโ€‹

The Rules docs section is intentionally split by decision-making flow:

  1. Guides (you are here) for adoption strategy and practical setup.
  2. Presets for curated rule sets (reference).
  3. Rule catalog for per-rule details and examples (catalog).

Pick a pathโ€‹

Path A โ€” "Just run Stylelint from ESLint"โ€‹

Use this if your main goal is unified lint execution in CI/editor:

  1. Follow Getting Started.
  2. Enable stylelintOnly.
  3. Tune the stylelint rule options if needed.

Path B โ€” "Also standardize config quality"โ€‹

Use this if you want consistent stylelint config shape across repos:

  1. Start with recommended.
  2. Review Config Authoring.
  3. Tighten with additional rule-level policies from Rule Catalog.

Path C โ€” "Need details before enabling"โ€‹

If you are evaluating behavior or migration risk:

Quick mapโ€‹

  1. Enable one preset (stylelintOnly or recommended) and run lint once.
  2. Apply autofixes and inspect diff quality in a PR.
  3. Add config policy rules gradually (not all at once) to reduce noisy rollouts.
  4. Lock in conventions via CI and editor integration.