|
| 1 | +module.exports = { |
| 2 | + root: true, |
| 3 | + env: { es6: true, node: true }, |
| 4 | + parser: '@typescript-eslint/parser', |
| 5 | + parserOptions: { |
| 6 | + ecmaVersion: 2020, |
| 7 | + sourceType: 'module', |
| 8 | + project: './tsconfig.eslint.json', |
| 9 | + }, |
| 10 | + plugins: ['import', 'prettier'], |
| 11 | + extends: [ |
| 12 | + 'airbnb-typescript/base', |
| 13 | + 'plugin:@typescript-eslint/recommended', |
| 14 | + 'plugin:@typescript-eslint/recommended-requiring-type-checking', |
| 15 | + ], |
| 16 | + settings: { |
| 17 | + 'import/parsers': { |
| 18 | + '@typescript-eslint/parser': ['.ts', '.tsx'], |
| 19 | + }, |
| 20 | + }, |
| 21 | + globals: { |
| 22 | + $log: false, |
| 23 | + $info: false, |
| 24 | + $option: false, |
| 25 | + $http: false, |
| 26 | + $file: false, |
| 27 | + $data: false, |
| 28 | + }, |
| 29 | + rules: { |
| 30 | + 'no-var': 'off', |
| 31 | + 'vars-on-top': 'off', |
| 32 | + 'prefer-const': 'off', |
| 33 | + 'no-return-assign': 'off', |
| 34 | + 'consistent-return': 'off', |
| 35 | + 'prefer-destructuring': 'off', |
| 36 | + 'no-underscore-dangle': 'off', |
| 37 | + 'object-curly-newline': 'off', |
| 38 | + // 'import/no-unresolved': 'error', |
| 39 | + 'import/no-mutable-exports': 'off', |
| 40 | + 'import/prefer-default-export': 'off', |
| 41 | + 'import/no-extraneous-dependencies': 'off', |
| 42 | + 'import/no-named-as-default-member': 'off', |
| 43 | + 'no-console': process.env.NODE_ENV === 'production' ? 'error' : 'off', |
| 44 | + 'max-len': ['error', { ignoreComments: true, code: 120, ignoreStrings: true }], |
| 45 | + '@typescript-eslint/require-await': 'off', |
| 46 | + '@typescript-eslint/no-unsafe-call': 'off', |
| 47 | + '@typescript-eslint/no-explicit-any': 'off', |
| 48 | + '@typescript-eslint/no-var-requires': 'off', |
| 49 | + '@typescript-eslint/no-unsafe-return': 'off', |
| 50 | + '@typescript-eslint/no-throw-literal': 'off', |
| 51 | + '@typescript-eslint/naming-convention': 'off', |
| 52 | + '@typescript-eslint/no-floating-promises': 'off', |
| 53 | + '@typescript-eslint/no-unsafe-assignment': 'off', |
| 54 | + '@typescript-eslint/no-unsafe-member-access': 'off', |
| 55 | + '@typescript-eslint/restrict-template-expressions': 'off', |
| 56 | + '@typescript-eslint/explicit-module-boundary-types': 'off', |
| 57 | + '@typescript-eslint/quotes': ['error', 'single', { allowTemplateLiterals: true }], |
| 58 | + }, |
| 59 | +}; |
0 commit comments