🚨(frontend) fix some eslint warnings
- Eslint tried to search some configs in the node_modules folder, we ignore node_modules in the eslint config now. - Adapt next eslint to use next/babel.
This commit is contained in:
@@ -17,4 +17,5 @@ module.exports = {
|
||||
sourceType: 'module',
|
||||
ecmaVersion: 'latest',
|
||||
},
|
||||
ignorePatterns: ['node_modules'],
|
||||
};
|
||||
|
||||
@@ -48,6 +48,7 @@ const globalRules = {
|
||||
],
|
||||
pathGroupsExcludedImportTypes: ['builtin'],
|
||||
'newlines-between': 'always',
|
||||
warnOnUnassignedImports: true,
|
||||
},
|
||||
],
|
||||
'no-alert': 'error',
|
||||
|
||||
@@ -46,4 +46,5 @@ module.exports = {
|
||||
},
|
||||
},
|
||||
],
|
||||
ignorePatterns: ['node_modules'],
|
||||
};
|
||||
|
||||
@@ -8,6 +8,11 @@ module.exports = {
|
||||
'plugin:@tanstack/eslint-plugin-query/recommended',
|
||||
'plugin:jsx-a11y/recommended',
|
||||
],
|
||||
parserOptions: {
|
||||
babelOptions: {
|
||||
presets: [require.resolve('next/babel')],
|
||||
},
|
||||
},
|
||||
settings: {
|
||||
'jsx-a11y': {
|
||||
polymorphicPropName: 'as',
|
||||
@@ -26,4 +31,5 @@ module.exports = {
|
||||
'react-hooks/exhaustive-deps': 'error',
|
||||
},
|
||||
overrides: common.eslintTS,
|
||||
ignorePatterns: ['node_modules'],
|
||||
};
|
||||
|
||||
@@ -21,4 +21,5 @@ module.exports = {
|
||||
plugins: ['playwright'],
|
||||
},
|
||||
],
|
||||
ignorePatterns: ['node_modules'],
|
||||
};
|
||||
|
||||
@@ -7,4 +7,5 @@ module.exports = {
|
||||
tsconfigRootDir: __dirname,
|
||||
project: ['./tsconfig.json'],
|
||||
},
|
||||
ignorePatterns: ['node_modules'],
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user