使用vue-cli构建项目 eslint报Expected linebreaks to be 'LF' but found 'CRLF'错误

使用 vue-cli 构建项目 eslint 报 Expected linebreaks to be ‘LF’ but found ‘CRLF’错误。
解决方法:
进入.eslintrc.js文件,rules里添加"linebreak-style": [0, "error", "windows"],如下

1
2
3
rules: {
"linebreak-style": [0, "error", "windows"]
}