报错信息:

% yarn dev       
yarn run v1.22.19
$ vue-cli-service serve
 INFO  Starting development server...
98% after emitting CopyPlugin

ERROR  Failed to compile with 1 error                               

Syntax Error: Error: No ESLint configuration found in /...


You may use special comments to disable some warnings.
Use // eslint-disable-next-line to ignore the next line.
Use /* eslint-disable */ to ignore all warnings in a file.

方式一:打开package.json将以下代码删除,重新运行项目 yarn dev

删除

"@vue/cli-plugin-eslint": "4.4.4",

在这里插入图片描述

yarn dev

在这里插入图片描述
运行就可以了

方式二:打开vue.config.js加入以下代码

module.exports = {
  lintOnSave:false  //关闭语法监测
}

在这里插入图片描述

运行就可以了

Logo

技术共进,成长同行——讯飞AI开发者社区

更多推荐