cosmos-explorer/.eslintrc.js
2022-09-03 12:48:02 +08:00

49 lines
1.5 KiB
JavaScript

module.exports = {
root: true,
env: {
node: true,
},
extends: [
'@vue/airbnb',
'plugin:vue/recommended',
'plugin:import/typescript',
// 'prettier/@typescript-eslint',
'plugin:@typescript-eslint/recommended',
// "plugin:prettier/recommended",
],
parser: 'vue-eslint-parser',
parserOptions: {
parser: '@typescript-eslint/parser',
ecmaVersion: 6,
sourceType: 'module',
ecmaFeatures: {
jsx: false,
modules: true,
experimentalObjectRestSpread: true,
},
},
rules: {
'no-console': process.env.NODE_ENV === 'production' ? 'error' : 'off',
'no-debugger': process.env.NODE_ENV === 'production' ? 'error' : 'off',
semi: ['error', 'never'],
'max-len': 'off',
'linebreak-style': 'off',
// camelcase: ['error', { properties: 'never', ignoreDestructuring: true, ignoreImports: true }],
'arrow-parens': ['error', 'as-needed'],
'vue/new-line-between-multi-line-property': 0,
'vue/multiline-html-element-content-newline': 0,
'vue/multi-word-component-names': 0,
'vue/no-mutating-props': 0,
'vue/v-slot-style': 0,
'@typescript-eslint/no-empty-function': 1,
camelcase: 0,
'vuejs-accessibility/click-events-have-key-events': 'off',
'vuejs-accessibility/mouse-events-have-key-events': 'off',
'vuejs-accessibility/anchor-has-content': 'off',
'no-unsafe-optional-chaining': 1,
'vuejs-accessibility/label-has-for': 1,
'import/extensions': 'off',
},
}