Eslint的检测机制Use // eslint-disable-next-line to ignore the next line. Use /* eslint-disable */ to ig
问题描述:提示vue3.0的vue项目在运行时候,会报Eslint的检测机制的错误129:3warningDelete `······`prettier/prettier130:1warningDelete `······`prettier/prettier131:1warningReplace `····}␍⏎` wit
·
问题描述:
提示
vue3.0的vue项目在运行时候,会报Eslint的检测机制的错误
129:3 warning Delete `······`
prettier/prettier
130:1 warning Delete `······`
prettier/prettier
131:1 warning Replace `····}␍⏎` with `}`
prettier/prettier
133:9 warning Insert `␍⏎`
prettier/prettier
✖ 114 problems (0 errors, 114 warnings)
0 errors and 114 warnings potentially fixable with the `--fix` option.
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.
原因分析:
这是因为在vue项目的vue.config.js文件中,将lintOnSave的值设为了true, 使用leslint检测机制解决方案:
将leslint检测机制关闭即可在vue.config.js中将module.exports = {}中的lintOnSave设置为false即可
module.exports = {
lintOnSave: false,
}
更多推荐
已为社区贡献2条内容
所有评论(0)