mirror of
https://github.com/pheralb/svgl.git
synced 2025-02-06 06:58:04 +08:00
⚙️ Upgrade eslint config to v9
This commit is contained in:
parent
da2cc7991d
commit
dc020ede7e
@ -1,13 +0,0 @@
|
|||||||
.DS_Store
|
|
||||||
node_modules
|
|
||||||
/build
|
|
||||||
/.svelte-kit
|
|
||||||
/package
|
|
||||||
.env
|
|
||||||
.env.*
|
|
||||||
!.env.example
|
|
||||||
|
|
||||||
# Ignore files for PNPM, NPM and YARN
|
|
||||||
pnpm-lock.yaml
|
|
||||||
package-lock.json
|
|
||||||
yarn.lock
|
|
@ -1,11 +1,17 @@
|
|||||||
import js from '@eslint/js';
|
import { fileURLToPath } from 'node:url';
|
||||||
import ts from 'typescript-eslint';
|
|
||||||
import svelte from 'eslint-plugin-svelte';
|
|
||||||
import prettier from 'eslint-config-prettier';
|
|
||||||
import globals from 'globals';
|
import globals from 'globals';
|
||||||
|
|
||||||
/** @type {import('eslint').Linter.Config[]} */
|
import js from '@eslint/js';
|
||||||
export default [
|
import { includeIgnoreFile } from '@eslint/compat';
|
||||||
|
import ts from 'typescript-eslint';
|
||||||
|
|
||||||
|
import svelte from 'eslint-plugin-svelte';
|
||||||
|
import prettier from 'eslint-config-prettier';
|
||||||
|
|
||||||
|
const gitignorePath = fileURLToPath(new URL('./.gitignore', import.meta.url));
|
||||||
|
|
||||||
|
export default ts.config(
|
||||||
|
includeIgnoreFile(gitignorePath),
|
||||||
js.configs.recommended,
|
js.configs.recommended,
|
||||||
...ts.configs.recommended,
|
...ts.configs.recommended,
|
||||||
...svelte.configs['flat/recommended'],
|
...svelte.configs['flat/recommended'],
|
||||||
@ -26,8 +32,5 @@ export default [
|
|||||||
parser: ts.parser
|
parser: ts.parser
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
|
||||||
{
|
|
||||||
ignores: ['build/', '.svelte-kit/', 'dist/']
|
|
||||||
}
|
}
|
||||||
];
|
);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user