1
+ import typescriptEslint from "@typescript-eslint/eslint-plugin" ;
2
+ import globals from "globals" ;
3
+ import tsParser from "@typescript-eslint/parser" ;
4
+ import path from "node:path" ;
5
+ import { fileURLToPath } from "node:url" ;
6
+ import js from "@eslint/js" ;
7
+ import { FlatCompat } from "@eslint/eslintrc" ;
8
+
9
+ const __filename = fileURLToPath ( import . meta. url ) ;
10
+ const __dirname = path . dirname ( __filename ) ;
11
+ const compat = new FlatCompat ( {
12
+ baseDirectory : __dirname ,
13
+ recommendedConfig : js . configs . recommended ,
14
+ allConfig : js . configs . all
15
+ } ) ;
16
+
17
+ export default [ {
18
+ ignores : [ "**/vscode.d.ts" , "**/vscode.proposed.d.ts" ] ,
19
+ } , ...compat . extends (
20
+ "eslint:recommended" ,
21
+ "plugin:@typescript-eslint/recommended" ,
22
+ "plugin:@typescript-eslint/eslint-recommended" ,
23
+ "prettier" ,
24
+ "plugin:prettier/recommended" ,
25
+ ) , {
26
+ plugins : {
27
+ "@typescript-eslint" : typescriptEslint ,
28
+ } ,
29
+
30
+ languageOptions : {
31
+ globals : {
32
+ ...globals . node ,
33
+ } ,
34
+
35
+ parser : tsParser ,
36
+ ecmaVersion : 2018 ,
37
+ sourceType : "module" ,
38
+
39
+ parserOptions : {
40
+ project : "./tsconfig.json" ,
41
+ } ,
42
+ } ,
43
+
44
+ rules : {
45
+ "@typescript-eslint/no-explicit-any" : 0 ,
46
+ "@typescript-eslint/explicit-function-return-type" : 0 ,
47
+ "@typescript-eslint/no-unused-vars" : 0 ,
48
+ "@typescript-eslint/no-require-imports" : 0 ,
49
+ "@typescript-eslint/no-unused-expressions" : 0 ,
50
+ } ,
51
+ } ] ;
0 commit comments