“No ESLint configuration found” error

后端 未结 11 2359
故里飘歌
故里飘歌 2021-02-01 16:03

Recently, we\'ve upgraded to ESLint 3.0.0 and started to receive the following message running the grunt eslint task:

> $ grunt eslint
Running \"         


        
11条回答
  •  暗喜
    暗喜 (楼主)
    2021-02-01 16:25

    Webpack

    I had eslint.rc file in my root project directory but event though I was getting error.
    Solution was to add exclude property to "eslint-loader" rule config:

    module.exports = {
      // ...
      module: {
        rules: [
          {
            test: /\.js$/,
            exclude: /node_modules/,
            loader: "eslint-loader",
            options: {
              // eslint options (if necessary)
            }
          },
        ],
      },
      // ...
    }
    

提交回复
热议问题