{"_id":"eslint-rspack-plugin","_rev":"3151191","name":"eslint-rspack-plugin","description":"A ESLint plugin for rspack","dist-tags":{"latest":"4.0.1-alpha"},"maintainers":[{"name":"hardfist","email":""}],"time":{"modified":"2023-11-28T06:05:07.000Z","created":"2023-04-24T10:01:49.791Z","4.0.1-alpha":"2023-10-18T08:18:56.153Z","4.0.0-alpha":"2023-04-24T10:01:49.791Z"},"users":{},"author":{"name":"Ricardo Gobbo de Souza","email":"ricardogobbosouza@yahoo.com.br"},"repository":{"type":"git","url":"git+https://github.com/rspack-contrib/eslint-rspack-plugin.git"},"versions":{"4.0.1-alpha":{"name":"eslint-rspack-plugin","version":"4.0.1-alpha","description":"A ESLint plugin for rspack","license":"MIT","repository":{"type":"git","url":"git+https://github.com/rspack-contrib/eslint-rspack-plugin.git"},"author":{"name":"Ricardo Gobbo de Souza","email":"ricardogobbosouza@yahoo.com.br"},"homepage":"https://github.com/rspack-contrib/eslint-rspack-plugin","bugs":{"url":"https://github.com/rspack-contrib/eslint-rspack-plugin/issues"},"funding":{"type":"opencollective","url":"https://opencollective.com/webpack"},"main":"dist/index.js","types":"types/index.d.ts","engines":{"node":">= 14.15.0"},"scripts":{"start":"npm run build -- -w","clean":"del-cli dist types","prebuild":"npm run clean","build:types":"tsc --declaration --emitDeclarationOnly --outDir types && prettier \"types/**/*.ts\" --write","build:code":"cross-env NODE_ENV=production babel src -d dist --copy-files","build":"npm-run-all -p \"build:**\"","commitlint":"commitlint --from=master","security":"npm audit","lint:prettier":"prettier -w --list-different .","lint:js":"eslint --cache .","lint:spelling":"cspell \"**/*.*\"","lint:types":"tsc --pretty --noEmit","lint":"npm-run-all -l -p \"lint:**\"","test:only":"cross-env NODE_ENV=test jest --testTimeout=60000","test:watch":"npm run test:only -- --watch","test:coverage":"npm run test:only -- --collectCoverageFrom=\"src/**/*.js\" --coverage","pretest":"npm run lint","test":"npm run test:coverage","prepare":"npm run build","release":"standard-version"},"peerDependencies":{"eslint":"^8.0.0","webpack":"^5.0.0"},"dependencies":{"@types/eslint":"^8.37.0","jest-worker":"^29.5.0","micromatch":"^4.0.5","normalize-path":"^3.0.0","schema-utils":"^4.0.0"},"devDependencies":{"@babel/cli":"^7.21.0","@babel/core":"^7.21.4","@babel/preset-env":"^7.21.4","@commitlint/cli":"^17.5.1","@commitlint/config-conventional":"^17.4.4","@types/fs-extra":"^9.0.13","@types/micromatch":"^4.0.2","@types/node":"^18.15.11","@types/normalize-path":"^3.0.0","@types/webpack":"^5.28.1","@webpack-contrib/eslint-config-webpack":"^3.0.0","babel-eslint":"^10.1.0","babel-jest":"^29.5.0","chokidar":"^3.5.3","cross-env":"^7.0.3","cspell":"^6.31.1","del":"^6.1.1","del-cli":"^4.0.1","eslint":"^8.38.0","eslint-config-prettier":"^8.8.0","eslint-plugin-import":"^2.27.5","fs-extra":"^10.1.0","husky":"^8.0.3","jest":"^29.5.0","lint-staged":"^13.2.1","npm-run-all":"^4.1.5","prettier":"^2.8.7","standard-version":"^9.5.0","typescript":"^5.0.4","webpack":"^5.78.0"},"keywords":["eslint","lint","linter","plugin","webpack"],"gitHead":"2df53822558ac210163ddf266ce55e46a1089bec","_id":"eslint-rspack-plugin@4.0.1-alpha","_nodeVersion":"16.17.1","_npmVersion":"7.24.2","dist":{"shasum":"81397401c97a0d8fc919e7ef7ace08013c7a75af","size":12426,"noattachment":false,"key":"/eslint-rspack-plugin/-/eslint-rspack-plugin-4.0.1-alpha.tgz","tarball":"http://registry.cnpm.dingdandao.com/eslint-rspack-plugin/download/eslint-rspack-plugin-4.0.1-alpha.tgz"},"_npmUser":{"name":"hardfist","email":"1562502418@qq.com"},"directories":{},"maintainers":[{"name":"hardfist","email":""}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/eslint-rspack-plugin_4.0.1-alpha_1697617135973_0.49178303391025313"},"_hasShrinkwrap":false,"_cnpmcore_publish_time":"2023-10-18T08:18:56.153Z","publish_time":1697617136153,"_source_registry_name":"default","_cnpm_publish_time":1697617136153},"4.0.0-alpha":{"name":"eslint-rspack-plugin","version":"4.0.0-alpha","description":"A ESLint plugin for webpack","license":"MIT","repository":{"type":"git","url":"git+https://github.com/webpack-contrib/eslint-webpack-plugin.git"},"author":{"name":"Ricardo Gobbo de Souza","email":"ricardogobbosouza@yahoo.com.br"},"homepage":"https://github.com/webpack-contrib/eslint-webpack-plugin","bugs":{"url":"https://github.com/webpack-contrib/eslint-webpack-plugin/issues"},"funding":{"type":"opencollective","url":"https://opencollective.com/webpack"},"main":"dist/index.js","types":"types/index.d.ts","engines":{"node":">= 14.15.0"},"scripts":{"start":"npm run build -- -w","clean":"del-cli dist types","prebuild":"npm run clean","build:types":"tsc --declaration --emitDeclarationOnly --outDir types && prettier \"types/**/*.ts\" --write","build:code":"cross-env NODE_ENV=production babel src -d dist --copy-files","build":"npm-run-all -p \"build:**\"","commitlint":"commitlint --from=master","security":"npm audit","lint:prettier":"prettier -w --list-different .","lint:js":"eslint --cache .","lint:spelling":"cspell \"**/*.*\"","lint:types":"tsc --pretty --noEmit","lint":"npm-run-all -l -p \"lint:**\"","test:only":"cross-env NODE_ENV=test jest --testTimeout=60000","test:watch":"npm run test:only -- --watch","test:coverage":"npm run test:only -- --collectCoverageFrom=\"src/**/*.js\" --coverage","pretest":"npm run lint","test":"npm run test:coverage","prepare":"npm run build","release":"standard-version"},"peerDependencies":{"eslint":"^8.0.0","webpack":"^5.0.0"},"dependencies":{"@types/eslint":"^8.37.0","jest-worker":"^29.5.0","micromatch":"^4.0.5","normalize-path":"^3.0.0","schema-utils":"^4.0.0"},"devDependencies":{"@babel/cli":"^7.21.0","@babel/core":"^7.21.4","@babel/preset-env":"^7.21.4","@commitlint/cli":"^17.5.1","@commitlint/config-conventional":"^17.4.4","@types/fs-extra":"^9.0.13","@types/micromatch":"^4.0.2","@types/node":"^18.15.11","@types/normalize-path":"^3.0.0","@types/webpack":"^5.28.1","@webpack-contrib/eslint-config-webpack":"^3.0.0","babel-eslint":"^10.1.0","babel-jest":"^29.5.0","chokidar":"^3.5.3","cross-env":"^7.0.3","cspell":"^6.31.1","del":"^6.1.1","del-cli":"^4.0.1","eslint":"^8.38.0","eslint-config-prettier":"^8.8.0","eslint-plugin-import":"^2.27.5","fs-extra":"^10.1.0","husky":"^8.0.3","jest":"^29.5.0","lint-staged":"^13.2.1","npm-run-all":"^4.1.5","prettier":"^2.8.7","standard-version":"^9.5.0","typescript":"^5.0.4","webpack":"^5.78.0"},"keywords":["eslint","lint","linter","plugin","webpack"],"gitHead":"5063454f6ad46bde3b878b1831d708017de9395e","_id":"eslint-rspack-plugin@4.0.0-alpha","_nodeVersion":"16.17.1","_npmVersion":"8.15.0","dist":{"shasum":"ac6c5f8088171a76fc29d5ef235b36978339f1e3","size":12437,"noattachment":false,"key":"/eslint-rspack-plugin/-/eslint-rspack-plugin-4.0.0-alpha.tgz","tarball":"http://registry.cnpm.dingdandao.com/eslint-rspack-plugin/download/eslint-rspack-plugin-4.0.0-alpha.tgz"},"_npmUser":{"name":"hardfist","email":"1562502418@qq.com"},"directories":{},"maintainers":[{"name":"hardfist","email":""}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/eslint-rspack-plugin_4.0.0-alpha_1682330509641_0.14644708495297465"},"_hasShrinkwrap":false,"_cnpmcore_publish_time":"2023-04-24T10:01:49.791Z","publish_time":1682330509791,"_cnpm_publish_time":1682330509791}},"readme":"<div align=\"center\">\n  <a href=\"https://github.com/eslint/eslint\"><img width=\"200\" height=\"200\" src=\"https://cdn.worldvectorlogo.com/logos/eslint.svg\"></a>\n  <a href=\"https://github.com/webpack/webpack\"><img width=\"200\" height=\"200\" src=\"https://webpack.js.org/assets/icon-square-big.svg\"></a>\n</div>\n\n[![npm][npm]][npm-url]\n[![node][node]][node-url]\n[![tests][tests]][tests-url]\n[![coverage][cover]][cover-url]\n[![chat][chat]][chat-url]\n[![size][size]][size-url]\n\n# eslint-rspack-plugin\n\n> This is eslint-rspack-plugin which works only with rspack . Fork from the [eslint-webpack-plugin](https://github.com/webpack-contrib/eslint-webpack-plugin/).\n\nThis plugin uses [`eslint`](https://eslint.org/) to find and fix problems in your JavaScript code\n\n## Getting Started\n\nTo begin, you'll need to install `eslint-rspack-plugin`:\n\n```console\nnpm install eslint-rspack-plugin --save-dev\n```\n\nor\n\n```console\nyarn add -D eslint-rspack-plugin\n```\n\nor\n\n```console\npnpm add -D eslint-rspack-plugin\n```\n\n> **Note**:\n>\n> You also need to install `eslint >= 8` from npm, if you haven't already:\n\n```console\nnpm install eslint --save-dev\n```\n\nor\n\n```console\nyarn add -D eslint\n```\n\nor\n\n```console\npnpm add -D eslint\n```\n\nThen add the plugin to your webpack config. For example:\n\n```js\nconst ESLintPlugin = require('eslint-rspack-plugin');\n\nmodule.exports = {\n  // ...\n  plugins: [new ESLintPlugin(options)],\n  // ...\n};\n```\n\n## Options\n\nYou can pass [eslint options](https://eslint.org/docs/developer-guide/nodejs-api#-new-eslintoptions).\n\n> **Note**\n>\n> The config option you provide will be passed to the `ESLint` class.\n> This is a different set of options than what you'd specify in `package.json` or `.eslintrc`.\n> See the [eslint docs](https://eslint.org/docs/developer-guide/nodejs-api#-new-eslintoptions) for more details.\n\n> **Warning**:\n>\n> In eslint-webpack-plugin version 1 the options were passed to the now deprecated [CLIEngine](https://eslint.org/docs/developer-guide/nodejs-api#cliengine).\n\n### `cache`\n\n- Type:\n\n```ts\ntype cache = boolean;\n```\n\n- Default: `true`\n\nThe cache is enabled by default to decrease execution time.\n\n### `cacheLocation`\n\n- Type:\n\n```ts\ntype cacheLocation = string;\n```\n\n- Default: `node_modules/.cache/eslint-webpack-plugin/.eslintcache`\n\nSpecify the path to the cache location. Can be a file or a directory.\n\n### `context`\n\n- Type:\n\n```ts\ntype context = string;\n```\n\n- Default: `compiler.context`\n\nA string indicating the root of your files.\n\n### `eslintPath`\n\n- Type:\n\n```ts\ntype eslintPath = string;\n```\n\n- Default: `eslint`\n\nPath to `eslint` instance that will be used for linting. If the `eslintPath` is a folder like a official eslint, or specify a `formatter` option. now you don't have to install `eslint`.\n\n### `extensions`\n\n- Type:\n\n```ts\ntype extensions = string | Array<string>;\n```\n\n- Default: `'js'`\n\nSpecify extensions that should be checked.\n\n### `exclude`\n\n- Type:\n\n```ts\ntype exclude = string | Array<string>;\n```\n\n- Default: `'node_modules'`\n\nSpecify the files and/or directories to exclude. Must be relative to `options.context`.\n\n### `resourceQueryExclude`\n\n- Type:\n\n```ts\ntype resourceQueryExclude = RegExp | Array<RegExp>;\n```\n\n- Default: `[]`\n\nSpecify the resource query to exclude.\n\n### `files`\n\n- Type:\n\n```ts\ntype files = string | Array<string>;\n```\n\n- Default: `null`\n\nSpecify directories, files, or globs. Must be relative to `options.context`.\nDirectories are traversed recursively looking for files matching `options.extensions`.\nFile and glob patterns ignore `options.extensions`.\n\n### `fix`\n\n- Type:\n\n```ts\ntype fix = boolean;\n```\n\n- Default: `false`\n\nWill enable [ESLint autofix feature](https://eslint.org/docs/developer-guide/nodejs-api#-eslintoutputfixesresults).\n\n**Be careful: this option will change source files.**\n\n### `formatter`\n\n- Type:\n\n```ts\ntype formatter = string| (\n  results:  Array<import('eslint').ESLint.LintResult>,\n  data?: import('eslint').ESLint.LintResultData | undefined\n) => string\n```\n\n- Default: `'stylish'`\n\nAccepts a function that will have one argument: an array of eslint messages (object). The function must return the output as a string. You can use official [eslint formatters](https://eslint.org/docs/user-guide/formatters/).\n\n### `lintDirtyModulesOnly`\n\n- Type:\n\n```ts\ntype lintDirtyModulesOnly = boolean;\n```\n\n- Default: `false`\n\nLint only changed files, skip lint on start.\n\n### `threads`\n\n- Type:\n\n```ts\ntype threads = boolean | number;\n```\n\n- Default: `false`\n\nWill run lint tasks across a thread pool. The pool size is automatic unless you specify a number.\n\n### Errors and Warning\n\n**By default the plugin will auto adjust error reporting depending on eslint errors/warnings counts.**\nYou can still force this behavior by using `emitError` **or** `emitWarning` options:\n\n#### `emitError`\n\n- Type:\n\n```ts\ntype emitError = boolean;\n```\n\n- Default: `true`\n\nThe errors found will always be emitted, to disable set to `false`.\n\n#### `emitWarning`\n\n- Type:\n\n```ts\ntype emitWarning = boolean;\n```\n\n- Default: `true`\n\nThe warnings found will always be emitted, to disable set to `false`.\n\n#### `failOnError`\n\n- Type:\n\n```ts\ntype failOnError = boolean;\n```\n\n- Default: `true`\n\nWill cause the module build to fail if there are any errors, to disable set to `false`.\n\n#### `failOnWarning`\n\n- Type:\n\n```ts\ntype failOnWarning = boolean;\n```\n\n- Default: `false`\n\nWill cause the module build to fail if there are any warnings, if set to `true`.\n\n#### `quiet`\n\n- Type:\n\n```ts\ntype quiet = boolean;\n```\n\n- Default: `false`\n\nWill process and report errors only and ignore warnings, if set to `true`.\n\n#### `outputReport`\n\n- Type:\n\n```ts\ntype outputReport =\n  | boolean\n  | {\n      filePath?: string | undefined;\n      formatter?:\n        | (\n            | string\n            | ((\n                results: Array<import('eslint').ESLint.LintResult>,\n                data?: import('eslint').ESLint.LintResultData | undefined\n              ) => string)\n          )\n        | undefined;\n    };\n```\n\n- Default: `false`\n\nWrite the output of the errors to a file, for example a checkstyle xml file for use for reporting on Jenkins CI.\n\nThe `filePath` is an absolute path or relative to the webpack config: `output.path`.\nYou can pass in a different `formatter` for the output file,\nif none is passed in the default/configured formatter will be used.\n\n## Changelog\n\n[Changelog](CHANGELOG.md)\n\n## License\n\n[MIT](./LICENSE)\n\n[npm]: https://img.shields.io/npm/v/eslint-webpack-plugin.svg\n[npm-url]: https://npmjs.com/package/eslint-webpack-plugin\n[node]: https://img.shields.io/node/v/eslint-webpack-plugin.svg\n[node-url]: https://nodejs.org\n[tests]: https://github.com/webpack-contrib/eslint-webpack-plugin/workflows/eslint-webpack-plugin/badge.svg\n[tests-url]: https://github.com/webpack-contrib/eslint-webpack-plugin/actions\n[cover]: https://codecov.io/gh/webpack-contrib/eslint-webpack-plugin/branch/master/graph/badge.svg\n[cover-url]: https://codecov.io/gh/webpack-contrib/eslint-webpack-plugin\n[chat]: https://badges.gitter.im/webpack/webpack.svg\n[chat-url]: https://gitter.im/webpack/webpack\n[size]: https://packagephobia.now.sh/badge?p=eslint-webpack-plugin\n[size-url]: https://packagephobia.now.sh/result?p=eslint-webpack-plugin\n","_attachments":{},"homepage":"https://github.com/rspack-contrib/eslint-rspack-plugin","bugs":{"url":"https://github.com/rspack-contrib/eslint-rspack-plugin/issues"},"license":"MIT"}