1- import tsParser from "@typescript-eslint/parser"
2- import tsPlugin from "@typescript-eslint/eslint-plugin"
1+ import globals from "globals"
2+ import eslint from "@eslint/js"
3+ import tseslint from "typescript-eslint"
4+ import { defineConfig , globalIgnores } from "eslint/config"
35
4- /** @type {import('eslint').Linter.Config[] } */
5- export default [
6+ export default defineConfig (
7+ eslint . configs . recommended ,
8+ tseslint . configs . recommended ,
69 {
10+ name : "Zag Overrides" ,
711 languageOptions : {
8- parser : tsParser ,
9- globals : {
10- node : true ,
11- } ,
12+ globals : globals . node ,
1213 } ,
13- plugins : {
14- "@typescript-eslint" : tsPlugin ,
14+
15+ linterOptions : {
16+ reportUnusedDisableDirectives : "error" ,
1517 } ,
16- files : [ "**/*.ts" , "**/*.tsx" ] ,
17- ignores : [ "dist" , "node_modules" , "coverage" , ".next" , "build" , "examples/vue-ts" , "plop-templates" , "**/*.d.ts" ] ,
1818
1919 rules : {
20+ "no-case-declarations" : "off" ,
21+ "no-empty" : "off" ,
22+ "prefer-const" : "off" ,
23+ "prefer-rest-params" : "off" ,
24+ "prefer-spread" : "off" ,
25+ "no-prototype-builtins" : "off" ,
26+
2027 "@typescript-eslint/ban-ts-comment" : "off" ,
21- "@typescript-eslint/no-use-before-define " : "off" ,
28+ "@typescript-eslint/no-empty-object-type " : "off" ,
2229 "@typescript-eslint/no-explicit-any" : "off" ,
23- "@typescript-eslint/no-non-null-assertion" : "off" ,
24- "no-param-reassign" : "off" ,
25- "prefer-spread" : "off" ,
26- "no-console" : "off" ,
27- "prefer-const" : "off" ,
28- "jsx-a11y/no-autofocus" : "off" ,
29- "import/named" : "off" ,
30- "import/prefer-default-export" : "off" ,
31- "no-underscore-dangle" : "off" ,
32- "no-shadow" : "off" ,
33- "no-plusplus" : "off" ,
34- "spaced-comment" : "off" ,
35- "guard-for-in" : "off" ,
36- "operator-assignment" : "off" ,
37- "prefer-destructuring" : "off" ,
38- "consistent-return" : "off" ,
39- "no-restricted-syntax" : "off" ,
40- "no-continue" : "off" ,
41- eqeqeq : "off" ,
42- "@typescript-eslint/dot-notation" : "off" ,
43- "no-bitwise" : "off" ,
44- "no-redeclare" : "off" ,
45- "@typescript-eslint/naming-convention" : "off" ,
46- "import/no-extraneous-dependencies" : "off" ,
47- "@typescript-eslint/lines-between-class-members" : "off" ,
48- "no-alert" : "off" ,
49- "@typescript-eslint/no-shadow" : "off" ,
50- "import/no-named-as-default" : "off" ,
51- "prefer-object-spread" : "off" ,
52- "arrow-body-style" : "off" ,
53- "import/namespace" : "off" ,
54- "jsx-a11y/label-has-associated-control" : "off" ,
30+ "@typescript-eslint/no-namespace" : "off" ,
31+ "@typescript-eslint/no-non-null-asserted-optional-chain" : "off" ,
32+ "@typescript-eslint/no-unsafe-function-type" : "off" ,
33+ "@typescript-eslint/no-unused-expressions" : "off" ,
5534 "@typescript-eslint/no-unused-vars" : [
5635 "error" ,
5736 {
@@ -60,14 +39,21 @@ export default [
6039 ignoreRestSiblings : true ,
6140 } ,
6241 ] ,
63- "default-case" : "off" ,
6442 } ,
6543 } ,
6644
67- {
68- files : [ "*.js" , "*.jsx" ] ,
69- parserOptions : {
70- project : "tsconfig.eslint.json" ,
71- } ,
72- } ,
73- ]
45+ globalIgnores (
46+ [
47+ "**/dist/" ,
48+ "**/coverage/" ,
49+ "**/.svelte-kit/" ,
50+ "**/.next/" ,
51+ "**/.nuxt/" ,
52+ "**/.contentlayer" ,
53+ "**/build/" ,
54+ "examples/vue-ts" ,
55+ "**/*.d.ts" ,
56+ ] ,
57+ "Zag Ignores" ,
58+ ) ,
59+ )
0 commit comments