This repository has no description
1import prettier from 'eslint-config-prettier';
2import path from 'node:path';
3import js from '@eslint/js';
4import svelte from 'eslint-plugin-svelte';
5import { defineConfig, includeIgnoreFile } from 'eslint/config';
6import globals from 'globals';
7import ts from 'typescript-eslint';
8
9const gitignorePath = path.resolve(import.meta.dirname, '.gitignore');
10
11export default defineConfig(
12 { ignores: ['src/lib/api/lexicons/'] },
13 includeIgnoreFile(gitignorePath),
14 js.configs.recommended,
15 ts.configs.recommended,
16 svelte.configs.recommended,
17 prettier,
18 svelte.configs.prettier,
19 {
20 languageOptions: { globals: { ...globals.browser, ...globals.node } },
21 rules: {
22 // typescript owns undefined-name checks.
23 'no-undef': 'off'
24 }
25 },
26 {
27 files: ['**/*.svelte', '**/*.svelte.ts', '**/*.svelte.js'],
28 languageOptions: {
29 parserOptions: {
30 projectService: true,
31 extraFileExtensions: ['.svelte'],
32 parser: ts.parser
33 }
34 }
35 },
36 {
37 rules: {}
38 }
39);