File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -138,12 +138,12 @@ module.exports = {
138
138
139
139
### lintOnSave
140
140
141
- - Type: ` boolean ` | ` 'error' `
141
+ - Type: ` boolean ` | ` 'warning' ` | ` 'default' ` | ` ' error'`
142
142
- Default: ` true `
143
143
144
144
是否在开发环境下通过 [ eslint-loader] ( https://github.com/webpack-contrib/eslint-loader ) 在每次保存时 lint 代码。这个值会在 [ ` @vue/cli-plugin-eslint ` ] ( https://github.com/vuejs/vue-cli/tree/dev/packages/%40vue/cli-plugin-eslint ) 被安装之后生效。
145
145
146
- 设置为 ` true ` 时,` eslint-loader ` 会将 lint 错误输出为编译警告。默认情况下,警告仅仅会被输出到命令行,且不会使得编译失败。
146
+ 设置为 ` true ` 或 ` 'warning' ` 时,` eslint-loader ` 会将 lint 错误输出为编译警告。默认情况下,警告仅仅会被输出到命令行,且不会使得编译失败。
147
147
148
148
如果你希望让 lint 错误在开发时直接显示在浏览器中,你可以使用 ` lintOnSave: 'error' ` 。这会强制 ` eslint-loader ` 将 lint 错误输出为编译错误,同时也意味着 lint 错误将会导致编译失败。
149
149
You can’t perform that action at this time.
0 commit comments