解决vue “Expected indentation of 0 spaces but found 2”报错问题

解决vue “Expected indentation of 0 spaces but found 2”报错问题

eslint报错
在这里插入图片描述
发现项目中并没有eslintrc.js文件。可以通过以下方式进行解决:
在package.json文件中的rules中添加几句
“no-unused-vars”: “off”,
“no-undef”: “off”,
“indent”: “off”
在这里插入图片描述

再重新npm install ---->npm run serve 重启就可以了,不会再出现此报错

猜你喜欢

转载自blog.csdn.net/Stars_in_rain/article/details/130600363