Skip to content

Commit 23f1ef1

Browse files
committed
chore(NODE-6938): update typescript to 5.8.3
1 parent 17650e1 commit 23f1ef1

File tree

7 files changed

+140
-120
lines changed

7 files changed

+140
-120
lines changed

package-lock.json

Lines changed: 105 additions & 90 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -27,16 +27,16 @@
2727
},
2828
"devDependencies": {
2929
"@istanbuljs/nyc-config-typescript": "^1.0.2",
30-
"@microsoft/api-extractor": "^7.47.5",
30+
"@microsoft/api-extractor": "^7.52.5",
3131
"@rollup/plugin-node-resolve": "^15.2.3",
32-
"@rollup/plugin-typescript": "^11.1.6",
32+
"@rollup/plugin-typescript": "^12.1.2",
3333
"@types/chai": "^4.3.17",
3434
"@types/mocha": "^10.0.7",
3535
"@types/node": "^22.1.0",
3636
"@types/sinon": "^17.0.3",
3737
"@types/sinon-chai": "^3.2.12",
38-
"@typescript-eslint/eslint-plugin": "^8.0.1",
39-
"@typescript-eslint/parser": "^8.0.1",
38+
"@typescript-eslint/eslint-plugin": "^8.31.1",
39+
"@typescript-eslint/parser": "^8.31.1",
4040
"benchmark": "^2.1.4",
4141
"chai": "^4.4.1",
4242
"chalk": "^5.3.0",
@@ -58,7 +58,7 @@
5858
"tar": "^7.4.3",
5959
"ts-node": "^10.9.2",
6060
"tsd": "^0.31.1",
61-
"typescript": "^5.5.4",
61+
"typescript": "^5.8.3",
6262
"typescript-cached-transpile": "0.0.6",
6363
"uuid": "^10.0.0"
6464
},

src/parser/on_demand/parse_to_elements.ts

Lines changed: 25 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -9,29 +9,31 @@ import { NumberUtils } from '../../utils/number_utils';
99
* - `minKey` is set to 255 so unsigned comparisons succeed
1010
* - Modify with caution, double check the bundle contains literals
1111
*/
12-
const enum BSONElementType {
13-
double = 1,
14-
string = 2,
15-
object = 3,
16-
array = 4,
17-
binData = 5,
18-
undefined = 6,
19-
objectId = 7,
20-
bool = 8,
21-
date = 9,
22-
null = 10,
23-
regex = 11,
24-
dbPointer = 12,
25-
javascript = 13,
26-
symbol = 14,
27-
javascriptWithScope = 15,
28-
int = 16,
29-
timestamp = 17,
30-
long = 18,
31-
decimal = 19,
32-
minKey = 255,
33-
maxKey = 127
34-
}
12+
const BSONElementType = {
13+
double: 1,
14+
string: 2,
15+
object: 3,
16+
array: 4,
17+
binData: 5,
18+
undefined: 6,
19+
objectId: 7,
20+
bool: 8,
21+
date: 9,
22+
null: 10,
23+
regex: 11,
24+
dbPointer: 12,
25+
javascript: 13,
26+
symbol: 14,
27+
javascriptWithScope: 15,
28+
int: 16,
29+
timestamp: 17,
30+
long: 18,
31+
decimal: 19,
32+
minKey: 255,
33+
maxKey: 127
34+
} as const;
35+
36+
type BSONElementType = typeof BSONElementType[keyof typeof BSONElementType];
3537

3638
/**
3739
* @public

test/bench/tsconfig.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@
88
"module": "commonjs",
99
"moduleResolution": "node",
1010
"skipLibCheck": true,
11+
"erasableSyntaxOnly": true,
1112
"lib": [
1213
"es2021"
1314
],

test/bundling/webpack/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
"devDependencies": {
1616
"@webpack-cli/generators": "^3.0.1",
1717
"ts-loader": "^9.4.2",
18-
"typescript": "^4.9.5",
18+
"typescript": "^5.8.3",
1919
"webpack": "^5.75.0",
2020
"webpack-cli": "^5.0.1"
2121
},

test/bundling/webpack/tsconfig.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,8 @@
44
"noImplicitAny": true,
55
"module": "es6",
66
"target": "es5",
7-
"allowJs": true
7+
"allowJs": true,
8+
"erasableSyntaxOnly": true
89
},
910
"files": ["src/index.ts"]
1011
}

tsconfig.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@
88
"module": "commonjs",
99
"moduleResolution": "node",
1010
"skipLibCheck": true,
11+
"erasableSyntaxOnly": true,
1112
"lib": [
1213
"es2021",
1314
"ES2022.Error"

0 commit comments

Comments
 (0)