diff options
Diffstat (limited to '')
-rw-r--r-- | frontend/.eslintrc.cjs | 49 |
1 files changed, 49 insertions, 0 deletions
diff --git a/frontend/.eslintrc.cjs b/frontend/.eslintrc.cjs new file mode 100644 index 0000000..c204ebe --- /dev/null +++ b/frontend/.eslintrc.cjs @@ -0,0 +1,49 @@ +module.exports = { + root: true, + extends: [ + 'eslint:recommended', + 'plugin:@typescript-eslint/recommended-type-checked', + 'plugin:@typescript-eslint/stylistic-type-checked', + 'plugin:svelte/recommended', + 'prettier' + ], + parser: '@typescript-eslint/parser', + plugins: ['@typescript-eslint'], + ignorePatterns: ['*.cjs'], + parserOptions: { + sourceType: 'module', + ecmaVersion: 2022, + extraFileExtensions: ['.svelte'], + project: true, + tsconfigRootDir: __dirname + }, + env: { + browser: true, + es2022: true, + node: true + }, + overrides: [ + { + files: ['*.svelte'], + parser: 'svelte-eslint-parser', + parserOptions: { + parser: '@typescript-eslint/parser' + }, + rules: { + '@typescript-eslint/no-unsafe-argument': 'off', + '@typescript-eslint/no-unsafe-assignment': 'off', + '@typescript-eslint/no-unsafe-call': 'off', + '@typescript-eslint/no-unsafe-enum-comparison': 'off', + '@typescript-eslint/no-unsafe-member-access': 'off' + } + }, + { + files: ['codegen.ts', 'svelte.config.js'], + extends: ['plugin:@typescript-eslint/disable-type-checked'] + } + ], + rules: { + 'no-console': 'warn', + eqeqeq: 'error' + } +}; |