Use prettier with eslint

This commit is contained in:
Jozef Izso 2025-06-07 15:33:52 +02:00
parent 4277f239de
commit 8a2a2093e5
Failed to extract signature

View file

@ -1,15 +1,20 @@
import github from 'eslint-plugin-github' import github from 'eslint-plugin-github'
import prettier from 'eslint-plugin-prettier'
export default [ export default [
github.getFlatConfigs().recommended, github.getFlatConfigs().recommended,
...github.getFlatConfigs().typescript, ...github.getFlatConfigs().typescript,
{ {
files: ['src/**/*.ts'], files: ['src/**/*.ts'],
plugins: {
prettier,
},
rules: { rules: {
'no-shadow': 'off', 'no-shadow': 'off',
'import/no-namespace': 'off', 'import/no-namespace': 'off',
'i18n-text/no-en': 'off', 'i18n-text/no-en': 'off',
'prefer-template': 'off', 'prefer-template': 'off',
'prettier/prettier': 'error',
"@typescript-eslint/array-type": ['error', {default: 'array'}], "@typescript-eslint/array-type": ['error', {default: 'array'}],
'@typescript-eslint/no-unused-vars': ['error', {varsIgnorePattern: '^_'}], '@typescript-eslint/no-unused-vars': ['error', {varsIgnorePattern: '^_'}],
'@typescript-eslint/no-shadow': ['error'], '@typescript-eslint/no-shadow': ['error'],