-
Notifications
You must be signed in to change notification settings - Fork 0
/
eslint.config.js
47 lines (46 loc) · 1.25 KB
/
eslint.config.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
import eslint from '@eslint/js';
import eslintPluginSvelte from 'eslint-plugin-svelte';
import svelteParser from 'svelte-eslint-parser';
import tsEslint from 'typescript-eslint';
export default tsEslint.config(
{
ignores: ['**/.*', '**/node_modules/**', '.vercel', '.sveltekit', '**/dist/**/*']
},
eslint.configs.recommended,
...tsEslint.configs.recommended,
...tsEslint.configs.stylistic,
...eslintPluginSvelte.configs['flat/prettier'],
{
files: ['**/*.svelte'],
languageOptions: {
parser: svelteParser,
parserOptions: {
parser: tsEslint.parser
}
}
},
{
files: ['**/*.ts', '**/*.js'],
languageOptions: {
parser: tsEslint.parser
}
},
{
rules: {
'@typescript-eslint/no-unused-vars': [
'warn',
{ argsIgnorePattern: '^_+$', varsIgnorePattern: '^\\$\\$(Props|Events|Slots)|_+$' }
],
'@typescript-eslint/explicit-module-boundary-types': 'off',
'@typescript-eslint/consistent-type-definitions': 'off',
'@typescript-eslint/array-type': 'off',
'@typescript-eslint/consistent-indexed-object-style': 'off',
'@typescript-eslint/prefer-for-of': 'off',
'no-console': ['error', { allow: ['warn', 'error'] }],
'no-undef': 'off',
'no-implied-eval': 'error',
'no-eval': 'error',
curly: 'error'
}
}
);