{"id":20582,"library":"stylelint-config-prettier","title":"stylelint-config-prettier","description":"Turns off all Stylelint rules that are unnecessary or might conflict with Prettier, allowing you to use your favorite shareable Stylelint config without its stylistic choices interfering. Current stable version is 9.0.5, released January 2023. The package is maintained sporadically; it disables stylistic rules so Prettier can take over formatting. As of Stylelint v15 (released February 2023), the stylistic rules have been deprecated, making this package unnecessary for users on v15+ who do not use deprecated rules. It includes a CLI helper to check for conflicting rules. Peer dependency ranges: stylelint >= 11.x < 15.","status":"active","version":"9.0.5","language":"javascript","source_language":"en","source_url":"https://github.com/prettier/stylelint-config-prettier","tags":["javascript","stylelint","prettier","config","lint","css"],"install":[{"cmd":"npm install stylelint-config-prettier","lang":"bash","label":"npm"},{"cmd":"yarn add stylelint-config-prettier","lang":"bash","label":"yarn"},{"cmd":"pnpm add stylelint-config-prettier","lang":"bash","label":"pnpm"}],"dependencies":[{"reason":"Peer dependency; used to disable stylelint rules.","package":"stylelint","optional":false}],"imports":[{"note":"Used in .stylelintrc.js as a string in extends array, not imported directly.","wrong":"const config = require('stylelint-config-prettier')","symbol":"config","correct":"module.exports = { extends: ['stylelint-config-prettier'] }"},{"note":"CLI tool is not an importable module; it's a bin script.","wrong":"Running npx stylelint-config-prettier-check without package.json script may fail if not in PATH.","symbol":"CLI check","correct":"Add script: \"stylelint-check\": \"stylelint-config-prettier-check\" and run npm run stylelint-check"},{"note":"The package has no index.js; extending the package name suffices.","wrong":"module.exports = { extends: ['stylelint-config-prettier/index'] }","symbol":"CJS require in config","correct":"module.exports = { extends: ['stylelint-config-prettier'] }"}],"quickstart":{"code":"npm install --save-dev stylelint-config-prettier stylelint@14\n# .stylelintrc.js\nmodule.exports = {\n  extends: [\n    'stylelint-config-standard',\n    'stylelint-config-prettier'\n  ]\n};\n// Check for conflicts:\n// Add to package.json scripts: \"stylelint-check\": \"stylelint-config-prettier-check\"\n// Run: npm run stylelint-check","lang":"javascript","description":"Shows how to install, extend the config (last place), and run the CLI check tool."},"warnings":[{"fix":"Remove stylelint-config-prettier from your extends array. Ensure your stylelint config does not rely on deprecated stylistic rules.","message":"As of Stylelint v15, all style-related rules have been deprecated. This package is unnecessary for users on v15+ who are not using deprecated rules.","severity":"deprecated","affected_versions":">=15.0.0"},{"fix":"Install stylelint-scss plugin if using SCSS and updating from v8.","message":"v9.0.0 drops some SCSS rules and sorts rules; may cause conflicts if SCSS plugin not installed.","severity":"breaking","affected_versions":">=9.0.0"},{"fix":"Ensure 'stylelint-config-prettier' is appended after all other configs in extends.","message":"Must be the last entry in the extends array to override other configs.","severity":"gotcha","affected_versions":">=1.0.0"},{"fix":"Update stylelint to v11+ and verify rules are disabled as expected.","message":"v8.0.0 disables rules linebreaks, no-empty-first-line, and unicode-bom; min stylelint version bumped to 11.","severity":"breaking","affected_versions":">=8.0.0"},{"fix":"Update to v6.0.0 or later to get security fixes.","message":"v6.0.0 security release updated dependencies; older versions may have vulnerability.","severity":"deprecated","affected_versions":"<6.0.0"}],"env_vars":null,"last_verified":"2026-04-25T00:00:00.000Z","next_check":"2026-07-24T00:00:00.000Z","problems":[{"fix":"Update to stylelint 14.x (or use stylelint-config-prettier v9+). In stylelint 15+, this package may not be needed.","cause":"stylelint-config-prettier disables rules by setting them to null, which newer stylelint versions reject.","error":"Configuration for rule \"color-no-invalid-hex\" is invalid: Expected a boolean value"},{"fix":"Run npm install --save-dev stylelint-config-prettier. Check that it's listed in devDependencies.","cause":"Package may not be installed or node_modules path missing.","error":"Cannot find module 'stylelint-config-prettier'"},{"fix":"Add a script in package.json: \"stylelint-check\": \"stylelint-config-prettier-check\" and run npm run stylelint-check.","cause":"The bin script is not in PATH, usually when using npx without a package.json script or without installing locally.","error":"cli: stylelint-config-prettier-check: command not found"},{"fix":"Remove stylelint-config-prettier from extends and update your stylelint config accordingly.","cause":"After upgrading to stylelint v15, the package disables rules that are already deprecated.","error":"Stylelint v15: Extending 'stylelint-config-prettier' has no effect since stylistic rules are deprecated."}],"ecosystem":"npm","meta_description":null,"install_score":null,"install_tag":null,"quickstart_score":null,"quickstart_tag":null}