ESLint plugin providing linting rules for scoped CSS in Vue.js components. Current stable version is 3.0.0, released in 2025, with active maintenance and regular releases (major every ~2 years). It supports CSS Level 4 selectors, SCSS (via postcss-scss), and Stylus (via postcss-styl), parsing <style>, <template>, and <script> blocks. Key differentiators: dedicated scoped CSS rules (e.g., no-unused-selector, no-deprecated-deep-combinator), built-in TypeScript types, and flat config support (ESLint >=9.38.0). Unlike generic CSS linting plugins, it understands Vue's scoped attributes and deep selectors.
npm install eslint-plugin-vue-scoped-cssVerified import paths — ran on the pinned version, not inferred.
Flat config example with recommended preset and custom rules.
Migrate to eslint.config.js flat config and upgrade Node.js to ^20.19.0 || ^22.13.0 || >=24.
Use unprefixed configs like 'base' or 'recommended' directly.
Install the appropriate peer: npm install --save-dev postcss-scss (for SCSS) or postcss-styl (for Stylus).
npm install --save-dev postcss-scss
Use eslint.config.js with import plugin from 'eslint-plugin-vue-scoped-css'; ...plugin.configs['recommended']
Use import plugin from 'eslint-plugin-vue-scoped-css' (default import), not named imports like { recommended }.