You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

27 lines
759 B
JavaScript

module.exports = {
root: true,
env: {
node: true
},
extends: [
'plugin:vue/essential',
'@vue/standard'
],
parserOptions: {
parser: 'babel-eslint'
},
rules: {
'no-console': process.env.NODE_ENV === 'production' ? 'warn' : 'off',
'no-debugger': process.env.NODE_ENV === 'production' ? 'warn' : 'off',
quotes: ['error', 'single'], //强制使用单引号
semi: ['error', 'never'], //强制不使用分号结尾
eqeqeq: ['error', 'always'], // 强制在任何情况下都使用 === 和 !==
'brace-style': ['error', '1tbs', { allowSingleLine: true }] //强制在代码块中使用一致的大括号风格
},
parserOptions: {
ecmaVersion: 6,
sourceType: 'module',
parser: 'babel-eslint'
}
}