Fix eslint setup

babel-eslint isn't working with node 16 anymore

In addition to the new packages, also turn the remaining Ember errors
into warnings, so we can fix them without `npm test` failing in the
meantime.
This commit is contained in:
Râu Cao
2022-10-06 12:28:02 +02:00
parent 441dc21894
commit 19553b9777
3 changed files with 424 additions and 288 deletions
+18 -4
View File
@@ -2,13 +2,21 @@
module.exports = {
root: true,
parser: 'babel-eslint',
parser: '@babel/eslint-parser',
parserOptions: {
ecmaVersion: 2018,
requireConfigFile: false,
ecmaVersion: 2020,
sourceType: 'module',
ecmaFeatures: {
legacyDecorators: true
}
},
babelOptions: {
babelrc: false,
configFile: false,
plugins: [
['@babel/plugin-proposal-decorators', { legacy: true }],
],
},
},
globals: {
console: true
@@ -28,7 +36,13 @@ module.exports = {
'no-console': 'off',
'ember/no-jquery': 'error',
'ember/require-computed-property-dependencies': 'warn',
'ember/no-observers': 'warn'
'ember/no-computed-properties-in-native-classes': 'warn',
'ember/no-observers': 'warn',
'ember/no-classic-classes': 'warn',
'ember/no-classic-components': 'warn',
'ember/no-controller-access-in-routes': 'warn',
'ember/no-actions-hash': 'warn',
'ember/require-tagless-components': 'warn'
},
overrides: [
// node files