0 Star 0 Fork 720

fanger/datav-vue

forked from pengxiaotian/datav-vue 
加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
克隆/下载
.eslintrc.js 2.33 KB
一键复制 编辑 原始数据 按行查看 历史
pengxiaotian 提交于 2021-12-21 00:19 . chore: 升级依赖
module.exports = {
root: true,
parser: 'vue-eslint-parser',
parserOptions: {
parser: '@typescript-eslint/parser',
sourceType: 'module',
ecmaFeatures: {
jsx: true,
tsx: true,
},
},
env: {
browser: true,
node: true,
},
plugins: [
'@typescript-eslint',
],
extends: [
'plugin:@typescript-eslint/recommended',
'plugin:vue/vue3-recommended',
],
rules: {
// js/ts https://eslint.org/docs/rules
'no-console': process.env.NODE_ENV === 'production' ? 'off' : 'off',
'no-debugger': process.env.NODE_ENV === 'production' ? 'error' : 'off',
'eol-last': 'error',
'no-trailing-spaces': 'error',
'comma-style': ['error', 'last'],
'comma-dangle': ['error', 'always-multiline'],
quotes: ['error', 'single', { avoidEscape: true, allowTemplateLiterals: true }],
camelcase: 0,
semi: ['error', 'never'],
indent: ['error', 2, { SwitchCase: 1 }],
'object-curly-spacing': ['error', 'always'],
'arrow-parens': ['error', 'as-needed'],
'quote-props': ['error', 'as-needed'],
'prefer-template': 'error',
/* https://github.com/typescript-eslint/typescript-eslint/tree/master/packages/eslint-plugin#supported-rules */
'@typescript-eslint/ban-types': 0,
'@typescript-eslint/no-empty-function': 0,
'@typescript-eslint/no-non-null-assertion': 0,
'@typescript-eslint/explicit-module-boundary-types': 'off',
'@typescript-eslint/no-explicit-any': 'off',
'@typescript-eslint/ban-ts-comment': 'off',
'@typescript-eslint/member-delimiter-style': [
'error',
{
multiline: {
delimiter: 'none',
requireLast: false,
},
singleline: {
delimiter: 'semi',
requireLast: true,
},
},
],
// vue https://eslint.vuejs.org/rules/
'vue/no-v-html': 'off',
'vue/singleline-html-element-content-newline': 'off',
'vue/html-self-closing': ['error', {
html: {
void: 'never',
normal: 'never',
component: 'always',
},
}],
'vue/max-attributes-per-line': ['error', {
singleline: 3,
multiline: 1,
}],
'vue/require-default-prop': 'off',
'vue/html-closing-bracket-spacing': 'error',
'vue/no-mutating-props': 'off',
'vue/multi-word-component-names': 'off',
'vue/v-on-event-hyphenation': 'off',
},
}
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
TypeScript
1
https://gitee.com/xiaofanger/datav-vue.git
git@gitee.com:xiaofanger/datav-vue.git
xiaofanger
datav-vue
datav-vue
dev

搜索帮助