1
0
mirror of https://github.com/troisjs/trois.git synced 2024-11-24 12:22:03 +08:00
trois/.eslintrc.js

57 lines
1.5 KiB
JavaScript
Raw Normal View History

2020-09-14 22:57:11 +08:00
module.exports = {
2021-04-15 23:50:41 +08:00
root: true,
2020-09-14 22:57:11 +08:00
env: {
browser: true,
es2020: true,
2021-04-15 23:50:41 +08:00
node: true,
2020-09-14 22:57:11 +08:00
},
extends: [
'plugin:vue/essential',
2021-04-15 23:50:41 +08:00
'@vue/standard',
'@vue/typescript/recommended',
2020-09-14 22:57:11 +08:00
'standard',
],
2021-04-15 23:50:41 +08:00
parser: 'vue-eslint-parser',
2020-09-14 22:57:11 +08:00
parserOptions: {
2021-04-15 23:50:41 +08:00
parser: '@typescript-eslint/parser',
2020-09-14 22:57:11 +08:00
},
2021-04-15 23:50:41 +08:00
// parserOptions: {
// ecmaVersion: 2020,
// },
2020-09-14 22:57:11 +08:00
rules: {
2021-04-15 23:50:41 +08:00
'no-console': process.env.NODE_ENV === 'production' ? 'warn' : 'off',
'no-debugger': process.env.NODE_ENV === 'production' ? 'warn' : 'off',
'semi': ['error', 'never'],
2020-09-14 22:57:11 +08:00
'space-before-function-paren': 'off',
'one-var': 'off',
'quotes': 'off',
'quote-props': 'off',
'object-curly-newline': 'off',
'no-unused-vars': 'warn',
// 'comma-dangle': ['warn', 'always-multiline'],
'comma-dangle': ['warn', {
'arrays': 'always-multiline',
'objects': 'always-multiline',
'imports': 'always-multiline',
'exports': 'always-multiline',
'functions': 'never',
}],
'indent': 'warn',
'no-new': 'off',
'object-property-newline': 'off',
'eqeqeq': 'warn',
'no-multiple-empty-lines': 'off',
2021-04-15 23:50:41 +08:00
'@typescript-eslint/ban-ts-comment': 'warn',
// '@typescript-eslint/ban-ts-comment': ['warn', {
// 'ts-ignore': 'allow-with-description',
// }],
// 'vue/valid-template-root': 'off',
'vue/no-multiple-template-root': 'off',
2021-04-16 10:12:41 +08:00
'no-empty-function': 'off',
2021-04-20 23:50:06 +08:00
'@typescript-eslint/no-empty-function': ['off'],
2020-09-14 22:57:11 +08:00
},
2021-04-15 23:50:41 +08:00
}