29 lines
678 B
JavaScript
29 lines
678 B
JavaScript
import parser from '@typescript-eslint/parser';
|
|
import plugin from '@typescript-eslint/eslint-plugin';
|
|
import prettierPlugin from 'eslint-plugin-prettier';
|
|
import prettierConfig from './.prettierrc.json' with { type: 'json' };
|
|
|
|
export default [
|
|
{
|
|
files: ['src/**/*.ts'],
|
|
languageOptions: {
|
|
parser,
|
|
parserOptions: {
|
|
ecmaVersion: 2020,
|
|
sourceType: 'module',
|
|
},
|
|
},
|
|
plugins: {
|
|
'@typescript-eslint': plugin,
|
|
prettier: prettierPlugin,
|
|
},
|
|
rules: {
|
|
...plugin.configs.recommended.rules,
|
|
'prettier/prettier': ['warn', prettierConfig],
|
|
},
|
|
},
|
|
{
|
|
ignores: ['dist/**', 'node_modules/**'],
|
|
},
|
|
];
|