Skip to content

Commit eca744f

Browse files
committed
1 parent 66d5f68 commit eca744f

4 files changed

Lines changed: 43 additions & 20 deletions

File tree

.eslintrc.js

Lines changed: 0 additions & 19 deletions
This file was deleted.

eslint.config.mjs

Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
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: ["src/authzedapi/**/*", "src/*.test.js"],
19+
}, ...compat.extends(
20+
"eslint:recommended",
21+
"plugin:@typescript-eslint/eslint-recommended",
22+
"plugin:@typescript-eslint/recommended",
23+
), {
24+
plugins: {
25+
"@typescript-eslint": typescriptEslint,
26+
},
27+
28+
languageOptions: {
29+
globals: {
30+
...globals.browser,
31+
...globals.commonjs,
32+
},
33+
34+
parser: tsParser,
35+
ecmaVersion: 12,
36+
sourceType: "script",
37+
},
38+
39+
rules: {},
40+
}];

package.json

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,8 @@
3333
"google-protobuf": "^3.21.4"
3434
},
3535
"devDependencies": {
36+
"@eslint/eslintrc": "^3.1.0",
37+
"@eslint/js": "^9.7.0",
3638
"@protobuf-ts/plugin": "^2.9.4",
3739
"@types/jasmine": "^5.1.4",
3840
"@types/jest": "^29.5.12",

yarn.lock

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,7 @@
7373
minimatch "^3.1.2"
7474
strip-json-comments "^3.1.1"
7575

76-
"@eslint/js@9.7.0":
76+
"@eslint/js@9.7.0", "@eslint/js@^9.7.0":
7777
version "9.7.0"
7878
resolved "https://registry.yarnpkg.com/@eslint/js/-/js-9.7.0.tgz#b712d802582f02b11cfdf83a85040a296afec3f0"
7979
integrity sha512-ChuWDQenef8OSFnvuxv0TCVxEwmu3+hPNKvM9B34qpM0rDRbjL8t5QkQeHHeAfsKQjuH9wS82WeCi1J/owatng==

0 commit comments

Comments
 (0)