webpack-contrib / eslint-webpack-plugin

A ESLint plugin for webpack
MIT License
254 stars 47 forks source link

Cache cannot be used,why delete cache this option,It also exists in eslint-loader #40

Closed JowayYoung closed 3 years ago

JowayYoung commented 3 years ago
// old
this.eslint = {
  cache: true,
  configFile: AbsPath(`../temp/configs/${useTs ? "ts" : "es"}lintrc.${frame}.js`, 1),
  formatter: EslintFriendlyFormatter,
  ignorePattern: eslintIgnores,
  rules: eslintRules
};
// new
this.eslint = new EslintPlugin({
  cache: true,
  extensions: ["js", "ts", "jsx", "tsx", "vue"],
  formatter: EslintFriendlyFormatter,
  overrideConfig: {
    ignorePatterns: eslintIgnores,
    rules: eslintRules
  },
  overrideConfigFile: AbsPath(`../temp/configs/${useTs ? "ts" : "es"}lintrc.${frame}.js`, 1)
});

cache don't work,why?

alexander-akait commented 3 years ago

Thank you for creating this issue. However, issues need to follow one of our templates so that we can clearly understand your particular circumstances.

Please help us help you by recreating the issue using one of our templates.

JowayYoung commented 3 years ago

thanks, I solved the problem