2024-11-04 08:55:26 +05:30
|
|
|
import typescriptEslint from '@typescript-eslint/eslint-plugin';
|
2026-02-23 15:41:07 +05:30
|
|
|
import importPlugin from 'eslint-plugin-import';
|
2024-11-04 08:55:26 +05:30
|
|
|
import jest from 'eslint-plugin-jest';
|
2026-02-23 15:41:07 +05:30
|
|
|
import prettierRecommended from 'eslint-plugin-prettier/recommended';
|
|
|
|
|
import eslintConfigPrettier from 'eslint-config-prettier';
|
2024-11-04 08:55:26 +05:30
|
|
|
import globals from 'globals';
|
|
|
|
|
import tsParser from '@typescript-eslint/parser';
|
|
|
|
|
import js from '@eslint/js';
|
|
|
|
|
|
|
|
|
|
export default [
|
2026-02-23 15:41:07 +05:30
|
|
|
js.configs.recommended,
|
|
|
|
|
...typescriptEslint.configs['flat/recommended'],
|
|
|
|
|
importPlugin.flatConfigs.errors,
|
|
|
|
|
importPlugin.flatConfigs.warnings,
|
|
|
|
|
importPlugin.flatConfigs.typescript,
|
|
|
|
|
prettierRecommended,
|
|
|
|
|
eslintConfigPrettier,
|
2024-11-04 08:55:26 +05:30
|
|
|
{
|
|
|
|
|
plugins: {
|
|
|
|
|
jest
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
languageOptions: {
|
|
|
|
|
globals: {
|
|
|
|
|
...globals.node,
|
|
|
|
|
...globals.jest
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
parser: tsParser,
|
|
|
|
|
ecmaVersion: 2021,
|
|
|
|
|
sourceType: 'module'
|
2026-01-20 07:47:37 +05:30
|
|
|
},
|
|
|
|
|
|
|
|
|
|
settings: {
|
|
|
|
|
'import/resolver': {
|
|
|
|
|
typescript: {
|
|
|
|
|
alwaysTryTypes: true,
|
|
|
|
|
project: './tsconfig.json'
|
|
|
|
|
},
|
|
|
|
|
node: {
|
|
|
|
|
extensions: ['.js', '.ts']
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
'import/parsers': {
|
|
|
|
|
'@typescript-eslint/parser': ['.ts']
|
|
|
|
|
}
|
2024-11-04 08:55:26 +05:30
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
];
|