2023-05-18 17:43:09 +02:00
|
|
|
/** @type {import('eslint').Linter.Config} */
|
2022-05-21 09:23:55 +02:00
|
|
|
module.exports = {
|
2023-07-01 06:50:47 +02:00
|
|
|
root: true,
|
|
|
|
extends: ['eslint:recommended', 'plugin:@typescript-eslint/recommended', 'plugin:svelte/recommended'],
|
|
|
|
parser: '@typescript-eslint/parser',
|
|
|
|
plugins: ['@typescript-eslint'],
|
|
|
|
parserOptions: {
|
|
|
|
sourceType: 'module',
|
|
|
|
ecmaVersion: 2020,
|
|
|
|
extraFileExtensions: ['.svelte'],
|
|
|
|
},
|
|
|
|
env: {
|
|
|
|
browser: true,
|
|
|
|
es2017: true,
|
|
|
|
node: true,
|
|
|
|
},
|
|
|
|
overrides: [
|
|
|
|
{
|
|
|
|
files: ['*.svelte'],
|
|
|
|
parser: 'svelte-eslint-parser',
|
|
|
|
parserOptions: {
|
|
|
|
parser: '@typescript-eslint/parser',
|
|
|
|
},
|
|
|
|
},
|
|
|
|
],
|
|
|
|
globals: {
|
|
|
|
NodeJS: true,
|
|
|
|
},
|
|
|
|
rules: {
|
|
|
|
'@typescript-eslint/no-unused-vars': [
|
|
|
|
'warn',
|
|
|
|
{
|
|
|
|
// Allow underscore (_) variables
|
|
|
|
argsIgnorePattern: '^_$',
|
|
|
|
varsIgnorePattern: '^_$',
|
|
|
|
},
|
|
|
|
],
|
|
|
|
},
|
2022-05-21 09:23:55 +02:00
|
|
|
};
|