gitbutler/packages/ui/.eslintrc.cjs

59 lines
1.2 KiB
JavaScript
Raw Normal View History

2023-02-24 12:46:41 +03:00
module.exports = {
root: true,
parser: '@typescript-eslint/parser',
2023-05-24 12:00:21 +03:00
extends: [
'eslint:recommended',
'plugin:@typescript-eslint/recommended',
'plugin:svelte/recommended',
'plugin:svelte/prettier',
'prettier'
],
plugins: ['svelte', '@typescript-eslint', 'square-svelte-store', 'import'],
2023-02-24 12:46:41 +03:00
parserOptions: {
sourceType: 'module',
2023-05-24 12:00:21 +03:00
ecmaVersion: 2020,
project: 'tsconfig.json',
extraFileExtensions: ['.svelte']
2023-02-24 12:46:41 +03:00
},
2023-05-24 12:00:21 +03:00
overrides: [
{
files: ['*.svelte'],
parser: 'svelte-eslint-parser',
parserOptions: {
parser: '@typescript-eslint/parser'
}
}
],
2023-02-24 12:46:41 +03:00
env: {
browser: true,
es2017: true,
node: true
2023-02-24 13:00:17 +03:00
},
rules: {
'import/no-cycle': 'error',
2023-05-24 12:00:21 +03:00
'svelte/no-at-html-tags': 'off',
2023-02-24 13:00:17 +03:00
'@typescript-eslint/no-namespace': 'off',
'@typescript-eslint/no-empty-function': 'off',
2023-05-12 13:17:06 +03:00
'@typescript-eslint/no-explicit-any': 'off',
2023-06-20 14:08:00 +03:00
'@typescript-eslint/no-unused-vars': [
'error', // or "error"
2023-06-20 14:08:00 +03:00
{
argsIgnorePattern: '^_',
varsIgnorePattern: '^_',
caughtErrorsIgnorePattern: '^_'
}
]
},
settings: {
'import/extensions': ['.ts'],
'import/parsers': {
'@typescript-eslint/parser': ['.ts']
},
'import/resolver': {
typescript: {
project: ['./tsconfig.json', './.svelte-kit/tsconfig.json']
}
}
2023-02-24 12:46:41 +03:00
}
};