module.exports = { root: true, env: { node: true }, extends: ['plugin:vue/essential', 'plugin:prettier/recommended'], parserOptions: { parser: '@babel/eslint-parser' }, rules: { '@typescript-eslint/type-annotation-spacing': [ 0, { before: true, after: true } ], 'no-console': process.env.NODE_ENV === 'production' ? 'warn' : 'off', 'no-debugger': process.env.NODE_ENV === 'production' ? 'warn' : 'off', quotes: ['error', 'single', 'avoid-escape'], //逗号风格,换行时在行首还是行尾 blockBindings: 0, // 块级作用域,允许使用let const 'no-useless-escape': 0, // 允许使用转义字符 'vue/multi-word-component-names': 0, //如何关闭此Eslint错误 html标签之前和之后的预期新换行符 'vue/singleline-html-element-content-newline': 'off', 'vue/multiline-html-element-content-newline': 'off', 'no-unused-vars': 'off', 'vue/no-mutating-props': 0, // eslint不建议子元素修改父元素传的props值 修改为可以修改 camelcase: 0, prettyhtml: 0, printWidth: 0, singleQuote: 0, wrapAttributes: 0, sortAttributes: 0 } }