|
| 1 | +// This file is in js due to #3514 |
| 2 | + |
| 3 | +module.exports = { |
| 4 | + root: true, |
| 5 | + plugins: [ |
| 6 | + 'promise', |
| 7 | + 'requirejs', |
| 8 | + ], |
| 9 | + extends: ['./.eslint-ce-static.yml'], |
| 10 | + rules: { |
| 11 | + 'promise/catch-or-return': 'off', |
| 12 | + 'promise/no-new-statics': 'error', |
| 13 | + 'promise/no-return-wrap': 'error', |
| 14 | + 'promise/param-names': 'error', |
| 15 | + 'promise/valid-params': 'error', |
| 16 | + }, |
| 17 | + overrides: [{ |
| 18 | + files: ['*.ts'], |
| 19 | + plugins: [ |
| 20 | + 'import', |
| 21 | + '@typescript-eslint', |
| 22 | + ], |
| 23 | + extends: [ |
| 24 | + './.eslint-ce-static.yml', |
| 25 | + 'plugin:@typescript-eslint/eslint-recommended', |
| 26 | + 'plugin:@typescript-eslint/recommended', |
| 27 | + 'plugin:import/typescript', |
| 28 | + ], |
| 29 | + env: { |
| 30 | + browser: true, |
| 31 | + es6: true, |
| 32 | + node: false, |
| 33 | + }, |
| 34 | + parser: '@typescript-eslint/parser', |
| 35 | + parserOptions: { |
| 36 | + sourceType: 'module', |
| 37 | + ecmaVersion: 'latest', |
| 38 | + tsconfigRootDir: __dirname, |
| 39 | + project: './tsconfig.json', |
| 40 | + }, |
| 41 | + rules: { |
| 42 | + '@typescript-eslint/no-empty-function': 'off', |
| 43 | + '@typescript-eslint/no-unused-vars': 'off', |
| 44 | + '@typescript-eslint/no-var-requires': 'off', // Needed for now, can't move some |
| 45 | + '@typescript-eslint/no-explicit-any': 'off', // Too much js code still exists |
| 46 | + '@typescript-eslint/ban-ts-comment': 'off', // We need some @ts-ignore at some points |
| 47 | + '@typescript-eslint/no-unnecessary-condition': 'warn', // for now just warn |
| 48 | + }, |
| 49 | + }], |
| 50 | +}; |
0 commit comments