From 4d8a9c9d08c951126730687919592328b8596a0b Mon Sep 17 00:00:00 2001 From: SnowCait Date: Sat, 7 Oct 2023 07:49:36 +0900 Subject: [PATCH] ESLint --- web/.eslintrc.cjs | 18 ++++++++++++------ 1 file changed, 12 insertions(+), 6 deletions(-) diff --git a/web/.eslintrc.cjs b/web/.eslintrc.cjs index 3ccf435f0..601ca3ecb 100644 --- a/web/.eslintrc.cjs +++ b/web/.eslintrc.cjs @@ -1,13 +1,16 @@ module.exports = { root: true, parser: '@typescript-eslint/parser', - extends: ['eslint:recommended', 'plugin:@typescript-eslint/recommended', 'prettier'], - plugins: ['svelte3', '@typescript-eslint'], + extends: ['plugin:svelte/recommended'], + plugins: ['@typescript-eslint'], ignorePatterns: ['*.cjs'], - overrides: [{ files: ['*.svelte'], processor: 'svelte3/svelte3' }], - settings: { - 'svelte3/typescript': () => require('typescript') - }, + overrides: [ + { + files: ['*.svelte'], + parser: 'svelte-eslint-parser', + parserOptions: { parser: '@typescript-eslint/parser' } + } + ], parserOptions: { sourceType: 'module', ecmaVersion: 2020 @@ -16,5 +19,8 @@ module.exports = { browser: true, es2017: true, node: true + }, + rules: { + 'svelte/valid-compile': 'off' } };