{"id":26639,"library":"web-code-lint","title":"web-code-lint","description":"A one-stop code lint tool integrating ESLint 9 (flat config), Prettier, Stylelint, Husky, lint-staged, Commitlint, and Vue/TypeScript support. v1.0.0 requires Node.js >=20.19.0 and is installable globally via pnpm or npm. It auto-generates configurations and Git hooks for new projects, using the project's lock file to select the appropriate package manager. Key differentiators: bundled VSCode auto-format config, ESLint flat config support, and no runtime peer dependencies beyond the project's own development stack.","status":"active","version":"1.0.0","language":"javascript","source_language":"en","source_url":null,"tags":["javascript","lint","eslint","prettier","stylelint","vue3","husky","lint-staged","standard"],"install":[{"cmd":"npm install web-code-lint","lang":"bash","label":"npm"},{"cmd":"yarn add web-code-lint","lang":"bash","label":"yarn"},{"cmd":"pnpm add web-code-lint","lang":"bash","label":"pnpm"}],"dependencies":[],"imports":[{"note":"ESM-only package, no CommonJS support.","wrong":"const init = require('web-code-lint')","symbol":"init","correct":"import { init } from 'web-code-lint'"},{"note":"lint is a script added to package.json by init, not an exported symbol.","wrong":"import { lint } from 'web-code-lint'","symbol":"lint","correct":"npm run lint"},{"note":"Same as lint, this is a script entry, not an importable function.","wrong":"const lintFix = require('web-code-lint').lintFix","symbol":"lint:fix","correct":"npm run lint:fix"}],"quickstart":{"code":"pnpm add -g web-code-lint\ncd /path/to/your/project\nweb-code-lint init\npnpm install\nnpm run lint","lang":"javascript","description":"Installs the tool globally, initializes lint config in a project, and runs the lint script."},"warnings":[{"fix":"Upgrade Node.js to >=20.19.0.","message":"Requires Node.js >=20.19.0; older versions will fail installation.","severity":"breaking","affected_versions":"<20.19"},{"fix":"Manually backup or commit your existing config before running init.","message":"The init command overwrites existing lint configuration files without backup.","severity":"deprecated","affected_versions":">=1.0.0"},{"fix":"If hooks fail, run 'pnpm install' (or equivalent) in the project root after init.","message":"Husky hooks use npx --no-install to run lint-staged; ensure lint-staged is installed as a dev dependency by init.","severity":"gotcha","affected_versions":">=1.0.0"},{"fix":"Merge the generated .vscode/settings.json with your existing settings manually.","message":"VSCode ESLint extension requires 'eslint.useFlatConfig' setting enabled; the init script adds a .vscode/settings.json with this setting, but it may conflict with an existing settings file.","severity":"gotcha","affected_versions":">=1.0.0"}],"env_vars":null,"last_verified":"2026-05-01T00:00:00.000Z","next_check":"2026-07-30T00:00:00.000Z","problems":[{"fix":"Run `pnpm install` (or npm/yarn) to ensure all plugins are installed.","cause":"Missing or incompatible peer dependency for ESLint plugin installed by init.","error":"Error: The module was not found. ESLint couldn't find the plugin 'xxx'."},{"fix":"Run `pnpm add eslint --save-dev` in the project root first, or re-run `web-code-lint init`.","cause":"Global web-code-lint tries to use local ESLint but it hasn't been installed yet.","error":"eslint: command not found"},{"fix":"Add `\"type\": \"module\"` to package.json, or rename config to eslint.config.cjs as CommonJS fallback.","cause":"ESLint flat config file (eslint.config.mjs) requires 'type: module' in package.json or .mjs extension, but the project may not have it set.","error":"SyntaxError: Cannot use import statement outside a module"}],"ecosystem":"npm","meta_description":null,"install_score":null,"install_tag":null,"quickstart_score":null,"quickstart_tag":null}