{"id":19956,"library":"eslint-plugin-sxzz","title":"eslint-plugin-sxzz","description":"A collection of ESLint rules for personal and project use, maintained by Kevin Deng. Current stable version is 0.4.4, with frequent releases. The plugin is ESM-only since v0.2.0, requires ESLint ^9.15.0 or ^10.0.0, and Node.js >=20.19.0. It includes TypeScript type definitions. Differentiators: custom rules like `require-package-field`, and breaking changes between versions (dropped CJS, dropped Node 18). Notable forked from eslint-plugin-antfu.","status":"active","version":"0.4.4","language":"javascript","source_language":"en","source_url":"https://github.com/sxzz/eslint-plugin-sxzz","tags":["javascript","typescript"],"install":[{"cmd":"npm install eslint-plugin-sxzz","lang":"bash","label":"npm"},{"cmd":"yarn add eslint-plugin-sxzz","lang":"bash","label":"yarn"},{"cmd":"pnpm add eslint-plugin-sxzz","lang":"bash","label":"pnpm"}],"dependencies":[{"reason":"peer dependency - plugin requires ESLint ^9.15.0 || ^10.0.0","package":"eslint","optional":false}],"imports":[{"note":"ESM-only since v0.2.0; CommonJS require will fail.","wrong":"const plugin = require('eslint-plugin-sxzz')","symbol":"default","correct":"import plugin from 'eslint-plugin-sxzz'"},{"note":"Named export for the rules object.","wrong":"import { rules } from 'eslint-plugin-sxzz/rules'","symbol":"rules","correct":"import { rules } from 'eslint-plugin-sxzz'"},{"note":"Named export for configs; may be undefined if not defined.","wrong":"import configs from 'eslint-plugin-sxzz/configs'","symbol":"configs","correct":"import { configs } from 'eslint-plugin-sxzz'"}],"quickstart":{"code":"// eslint.config.js\nimport plugin from 'eslint-plugin-sxzz';\nexport default [\n  {\n    plugins: { sxzz: plugin },\n    rules: {\n      'sxzz/require-package-field': 'error',\n    },\n  },\n];","lang":"javascript","description":"Configure ESLint flat config to use eslint-plugin-sxzz with a custom rule."},"warnings":[{"fix":"Use ESM imports (import) instead of require().","message":"Dropped CJS build in v0.2.0; ESM-only.","severity":"breaking","affected_versions":">=0.2.0"},{"fix":"Upgrade Node.js to >=20.19.0.","message":"Node.js <20.19.0 is no longer supported since v0.3.0.","severity":"breaking","affected_versions":">=0.3.0"},{"fix":"Check TypeScript config; may need to update type imports.","message":"ESLint typegen changes in v0.4.0 may break type definitions.","severity":"breaking","affected_versions":">=0.4.0 <0.5.0"},{"fix":"Add plugin.sxzz to plugins and enable individual rules.","message":"Plugin does not export a recommended config; you must manually configure rules.","severity":"gotcha","affected_versions":">=0.0.0"},{"fix":"Use 'eslint.config.js' or 'eslint.config.mjs' with flat config.","message":"ESLint flat config is required; legacy .eslintrc format not supported.","severity":"deprecated","affected_versions":">=0.1.0"}],"env_vars":null,"last_verified":"2026-04-25T00:00:00.000Z","next_check":"2026-07-24T00:00:00.000Z","problems":[{"fix":"Run 'npm install eslint-plugin-sxzz' and ensure package.json has 'type':'module' or use .mjs extension.","cause":"Package not installed or ESM import used in CJS project.","error":"Cannot find module 'eslint-plugin-sxzz'"},{"fix":"Use import plugin from 'eslint-plugin-sxzz' (ESM) and set it as { plugins: { sxzz: plugin } }.","cause":"Plugin imported incorrectly (e.g., using require in CJS or missing default export).","error":"Failed to load plugin 'sxzz': Plugin is not an object or function"},{"fix":"Check available rules in documentation; use correct rule name like 'sxzz/require-package-field'.","cause":"Rule name misspelled or not available in this version.","error":"ESLint: Error while loading rule 'sxzz/require-package-field': Rule not found"}],"ecosystem":"npm","meta_description":null,"install_score":null,"install_tag":null,"quickstart_score":null,"quickstart_tag":null}