{"id":25884,"library":"lint-to-the-future-stylelint","title":"lint-to-the-future-stylelint","description":"A plugin for lint-to-the-future that integrates with stylelint to lint CSS files and track linting ignore comments. Current stable version 2.1.0 (released March 2025). Used to progressively enforce stylelint rules by marking files for future linting. Differentiates from direct stylelint usage by allowing incremental adoption via lint-to-the-future's ignore comment tracking. Works with stylelint v13, v14, and v15+. Requires Node 12+ (v2.x requires Node 18+).","status":"active","version":"2.1.0","language":"javascript","source_language":"en","source_url":"https://github.com/mansona/lint-to-the-future-stylelint","tags":["javascript"],"install":[{"cmd":"npm install lint-to-the-future-stylelint","lang":"bash","label":"npm"},{"cmd":"yarn add lint-to-the-future-stylelint","lang":"bash","label":"yarn"},{"cmd":"pnpm add lint-to-the-future-stylelint","lang":"bash","label":"pnpm"}],"dependencies":[{"reason":"peer dependency required for linting CSS","package":"stylelint","optional":false}],"imports":[{"note":"Package is ESM-only since v2.0.0. Requires Node >=18.","wrong":"const lintToTheFutureStylelint = require('lint-to-the-future-stylelint')","symbol":"lintToTheFutureStylelint","correct":"import lintToTheFutureStylelint from 'lint-to-the-future-stylelint'"},{"note":"Named export is available for TypeScript users. Correct symbol is LintToTheFutureStylelintPlugin.","wrong":"import { LintToTheFutureStylelint } from 'lint-to-the-future-stylelint'","symbol":"LintToTheFutureStylelintPlugin","correct":"import { LintToTheFutureStylelintPlugin } from 'lint-to-the-future-stylelint'"},{"note":"Default export is the plugin instance. Avoid namespace import for correct usage.","wrong":"import * as ltffStylelint from 'lint-to-the-future-stylelint'","symbol":"default","correct":"import ltffStylelint from 'lint-to-the-future-stylelint'"}],"quickstart":{"code":"import { LintToTheFutureStylelintPlugin } from 'lint-to-the-future-stylelint';\n\nconst plugin = new LintToTheFutureStylelintPlugin({\n  // optional: specify stylelint config (default: stylelint's standard config)\n  config: {\n    extends: 'stylelint-config-standard'\n  }\n});\n\n// Use with lint-to-the-future:\nimport lintToTheFuture from 'lint-to-the-future';\nconst lttf = new lintToTheFuture({\n  plugins: [plugin]\n});\n\n// Then run lttf.process() to check files with stylelint-disable comments\nawait lttf.process({ files: ['src/**/*.css'] });","lang":"typescript","description":"Shows how to create the plugin and use it with lint-to-the-future to track stylelint-disable comments."},"warnings":[{"fix":"Upgrade Node to >=18 and ensure project uses ESM (type: module or .mjs extension). Remove any require() calls for this package.","message":"v2.0.0 drops support for Node 14 and 16, and is ESM-only.","severity":"breaking","affected_versions":">=2.0.0"},{"fix":"Update to v2.1.0 which supports stylelint v15+. For stylelint v13/v14, stay on v1.x.","message":"stylelint v13 and v14 are still supported as peer dependencies, but stylelint v15+ is recommended.","severity":"deprecated","affected_versions":">=1.0.0 <2.0.0"},{"fix":"Ensure your CSS files contain the appropriate stylelint-disable comments for lint-to-the-future to track.","message":"The plugin only processes files with /* stylelint-disable */ comments. Files without such comments are ignored.","severity":"gotcha","affected_versions":">=0.1.0"},{"fix":"Review your ignore patterns to ensure they work with globby syntax. Refer to globby documentation.","message":"The plugin uses globby for file globbing since v2.1.0; behavior may differ from previous micromatch-based ignoring.","severity":"gotcha","affected_versions":">=2.1.0"}],"env_vars":null,"last_verified":"2026-05-01T00:00:00.000Z","next_check":"2026-07-30T00:00:00.000Z","problems":[{"fix":"npm install lint-to-the-future-stylelint@2 and use import syntax.","cause":"Package not installed or wrong import path (CommonJS require in ESM-only v2).","error":"Cannot find module 'lint-to-the-future-stylelint'"},{"fix":"Use import lintToTheFutureStylelint from 'lint-to-the-future-stylelint' (default import).","cause":"Using require() or import * as when package is ESM-only.","error":"The requested module 'lint-to-the-future-stylelint' does not provide an export named 'default'"},{"fix":"Upgrade Node to >=18 or downgrade stylelint to v14.","cause":"Incompatible Node version for stylelint v15.","error":"stylelint: Stylelint v15 requires Node >=18"},{"fix":"Use the 'config' property as a stylelint config object, not 'configFile'.","cause":"Using a config option that doesn't exist (likely confused with stylelint's configFile).","error":"lint-to-the-future-stylelint: Unknown plugin option 'configFile'"}],"ecosystem":"npm","meta_description":null,"install_score":null,"install_tag":null,"quickstart_score":null,"quickstart_tag":null}