Skip to content

Commit 0a64363

Browse files
Merge pull request #128 from microsoft/zhiyuanliang/upgrade-dependency
Upgrade dev dependency
1 parent 9ca2d53 commit 0a64363

28 files changed

+8194
-1469
lines changed

.github/workflows/ci.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ jobs:
1818

1919
strategy:
2020
matrix:
21-
node-version: [18.x, 20.x]
21+
node-version: [18.x, 20.x, 22.x, 24.x]
2222

2323
defaults:
2424
run:

src/feature-management-applicationinsights-browser/.eslintrc

Lines changed: 0 additions & 60 deletions
This file was deleted.
Lines changed: 78 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,78 @@
1+
import { defineConfig, globalIgnores } from "eslint/config";
2+
import typescriptEslint from "@typescript-eslint/eslint-plugin";
3+
import globals from "globals";
4+
import tsParser from "@typescript-eslint/parser";
5+
import path from "node:path";
6+
import { fileURLToPath } from "node:url";
7+
import js from "@eslint/js";
8+
import { FlatCompat } from "@eslint/eslintrc";
9+
10+
const __filename = fileURLToPath(import.meta.url);
11+
const __dirname = path.dirname(__filename);
12+
const compat = new FlatCompat({
13+
baseDirectory: __dirname,
14+
recommendedConfig: js.configs.recommended,
15+
allConfig: js.configs.all
16+
});
17+
18+
export default defineConfig([globalIgnores([
19+
"node_modules/**",
20+
"dist/**",
21+
"dist-esm/**",
22+
"types/**",
23+
"*.min.js",
24+
"coverage/**"
25+
]), {
26+
extends: compat.extends("eslint:recommended", "plugin:@typescript-eslint/recommended"),
27+
28+
plugins: {
29+
"@typescript-eslint": typescriptEslint,
30+
},
31+
32+
languageOptions: {
33+
globals: {
34+
...globals.browser,
35+
...globals.commonjs,
36+
...globals.node,
37+
...globals.mocha,
38+
},
39+
40+
parser: tsParser,
41+
ecmaVersion: "latest",
42+
sourceType: "commonjs",
43+
},
44+
45+
rules: {
46+
"keyword-spacing": ["error", {
47+
before: true,
48+
after: true,
49+
}],
50+
51+
quotes: ["error", "double", {
52+
avoidEscape: true,
53+
}],
54+
55+
"@typescript-eslint/no-explicit-any": "off",
56+
"eol-last": ["error", "always"],
57+
"no-trailing-spaces": "error",
58+
"space-before-blocks": ["error", "always"],
59+
"no-multi-spaces": "error",
60+
61+
"no-multiple-empty-lines": ["error", {
62+
max: 1,
63+
}],
64+
65+
semi: ["error", "always"],
66+
},
67+
}, {
68+
files: ["**/.eslintrc.{js,cjs}"],
69+
70+
languageOptions: {
71+
globals: {
72+
...globals.node,
73+
},
74+
75+
ecmaVersion: 5,
76+
sourceType: "commonjs",
77+
},
78+
}]);

0 commit comments

Comments
 (0)