Skip to content

Commit 01713a8

Browse files
committed
fix exports in package.json to work with ts's implementation of node16 moduleResolution
1 parent 98a0efb commit 01713a8

File tree

20 files changed

+184
-76
lines changed

20 files changed

+184
-76
lines changed

packages/device-id/package.json

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -23,14 +23,19 @@
2323
],
2424
"license": "Apache-2.0",
2525
"main": "dist/index.js",
26+
"types": "./dist/index.d.ts",
2627
"exports": {
2728
".": {
28-
"require": "./dist/index.js",
29-
"import": "./dist/.esm-wrapper.mjs",
30-
"types": "./dist/index.d.ts"
29+
"require": {
30+
"default": "./dist/index.js",
31+
"types": "./dist/index.d.ts"
32+
},
33+
"import": {
34+
"default": "./dist/.esm-wrapper.mjs",
35+
"types": "./dist/index.d.ts"
36+
}
3137
}
3238
},
33-
"types": "./dist/index.d.ts",
3439
"scripts": {
3540
"bootstrap": "npm run compile",
3641
"prepublishOnly": "npm run compile",

packages/devtools-proxy-support/package.json

Lines changed: 17 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -23,19 +23,29 @@
2323
],
2424
"license": "Apache-2.0",
2525
"main": "dist/index.js",
26+
"types": "./dist/index.d.ts",
2627
"exports": {
2728
".": {
28-
"require": "./dist/index.js",
29-
"import": "./dist/.esm-wrapper.mjs",
30-
"types": "./dist/index.d.ts"
29+
"require": {
30+
"default": "./dist/index.js",
31+
"types": "./dist/index.d.ts"
32+
},
33+
"import": {
34+
"default": "./dist/.esm-wrapper.mjs",
35+
"types": "./dist/index.d.ts"
36+
}
3137
},
3238
"./proxy-options": {
33-
"require": "./dist/proxy-options-public.js",
34-
"import": "./dist/.esm-wrapper-po.mjs",
35-
"types": "./dist/proxy-options-public.d.ts"
39+
"require": {
40+
"default": "./dist/proxy-options-public.js",
41+
"types": "./dist/proxy-options-public.d.ts"
42+
},
43+
"import": {
44+
"default": "./dist/.esm-wrapper-po.mjs",
45+
"types": "./dist/proxy-options-public.d.ts"
46+
}
3647
}
3748
},
38-
"types": "./dist/index.d.ts",
3949
"scripts": {
4050
"bootstrap": "npm run compile",
4151
"prepublishOnly": "npm run compile",

packages/dl-center/package.json

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -23,12 +23,17 @@
2323
],
2424
"license": "Apache-2.0",
2525
"main": "dist/index.js",
26+
"types": "./dist/index.d.ts",
2627
"exports": {
27-
"require": "./dist/index.js",
28-
"import": "./dist/.esm-wrapper.mjs",
29-
"types": "./dist/index.d.ts"
28+
"require": {
29+
"default": "./dist/index.js",
30+
"types": "./dist/index.d.ts"
31+
},
32+
"import": {
33+
"defualt": "./dist/.esm-wrapper.mjs",
34+
"types": "./dist/index.d.ts"
35+
}
3036
},
31-
"types": "./dist/index.d.ts",
3237
"scripts": {
3338
"generate-config-from-schema": "json2ts -i src/download-center-config.schema.json -o src/download-center-config.ts --bannerComment \"/* AUTO-GENERATED DO NOT EDIT. */\"",
3439
"pretest": "npm run generate-config-from-schema && npm run reformat",

packages/download-url/package.json

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -21,12 +21,17 @@
2121
"reformat": "npm run prettier -- --write ."
2222
},
2323
"main": "lib/index.js",
24+
"types": "lib/index.d.ts",
2425
"exports": {
25-
"require": "./lib/index.js",
26-
"import": "./.esm-wrapper.mjs",
27-
"types": "./lib/index.d.ts"
26+
"require": {
27+
"default": "./lib/index.js",
28+
"types": "./lib/index.d.ts"
29+
},
30+
"import": {
31+
"default": "./.esm-wrapper.mjs",
32+
"types": "./lib/index.d.ts"
33+
}
2834
},
29-
"typings": "lib/index.d.ts",
3035
"bin": {
3136
"mongodb-download-url": "bin/mongodb-download-url.js"
3237
},

packages/get-os-info/package.json

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -24,9 +24,14 @@
2424
"license": "Apache-2.0",
2525
"main": "dist/index.js",
2626
"exports": {
27-
"require": "./dist/index.js",
28-
"import": "./dist/.esm-wrapper.mjs",
29-
"types": "./dist/index.d.ts"
27+
"require": {
28+
"default": "./dist/index.js",
29+
"types": "./dist/index.d.ts"
30+
},
31+
"import": {
32+
"default": "./dist/.esm-wrapper.mjs",
33+
"types": "./dist/index.d.ts"
34+
}
3035
},
3136
"types": "./dist/index.d.ts",
3237
"scripts": {

packages/mongodb-cloud-info/package.json

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -23,12 +23,17 @@
2323
],
2424
"license": "Apache-2.0",
2525
"main": "dist/index.js",
26+
"types": "./dist/index.d.ts",
2627
"exports": {
27-
"require": "./dist/index.js",
28-
"import": "./dist/.esm-wrapper.mjs",
29-
"types": "./dist/index.d.ts"
28+
"require": {
29+
"default": "./dist/index.js",
30+
"types": "./dist/index.d.ts"
31+
},
32+
"import": {
33+
"default": "./dist/.esm-wrapper.mjs",
34+
"types": "./dist/index.d.ts"
35+
}
3036
},
31-
"types": "./dist/index.d.ts",
3237
"scripts": {
3338
"bootstrap": "npm run compile",
3439
"prepublishOnly": "npm run compile",

packages/mongodb-constants/package.json

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -23,12 +23,17 @@
2323
],
2424
"license": "Apache-2.0",
2525
"main": "dist/index.js",
26+
"types": "./dist/index.d.ts",
2627
"exports": {
27-
"require": "./dist/index.js",
28-
"import": "./dist/.esm-wrapper.mjs",
29-
"types": "./dist/index.d.ts"
28+
"require": {
29+
"default": "./dist/index.js",
30+
"types": "./dist/index.d.ts"
31+
},
32+
"import": {
33+
"default": "./dist/.esm-wrapper.mjs",
34+
"types": "./dist/index.d.ts"
35+
}
3036
},
31-
"types": "./dist/index.d.ts",
3237
"scripts": {
3338
"bootstrap": "npm run compile",
3439
"prepublishOnly": "npm run compile",

packages/mongodb-downloader/package.json

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -23,12 +23,17 @@
2323
],
2424
"license": "Apache-2.0",
2525
"main": "dist/index.js",
26+
"types": "./dist/index.d.ts",
2627
"exports": {
27-
"require": "./dist/index.js",
28-
"import": "./dist/.esm-wrapper.mjs",
29-
"types": "./dist/index.d.ts"
28+
"require": {
29+
"default": "./dist/index.js",
30+
"types": "./dist/index.d.ts"
31+
},
32+
"import": {
33+
"default": "./dist/.esm-wrapper.mjs",
34+
"types": "./dist/index.d.ts"
35+
}
3036
},
31-
"types": "./dist/index.d.ts",
3237
"scripts": {
3338
"bootstrap": "npm run compile",
3439
"prepublishOnly": "npm run compile",

packages/mongodb-redact/package.json

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -23,12 +23,17 @@
2323
],
2424
"license": "Apache-2.0",
2525
"main": "dist/index.js",
26+
"types": "./dist/index.d.ts",
2627
"exports": {
27-
"require": "./dist/index.js",
28-
"import": "./dist/.esm-wrapper.mjs",
29-
"types": "./dist/index.d.ts"
28+
"require": {
29+
"default": "./dist/index.js",
30+
"types": "./dist/index.d.ts"
31+
},
32+
"import": {
33+
"default": "./dist/.esm-wrapper.mjs",
34+
"types": "./dist/index.d.ts"
35+
}
3036
},
31-
"types": "./dist/index.d.ts",
3237
"scripts": {
3338
"bootstrap": "npm run compile",
3439
"prepublishOnly": "npm run compile",

packages/mongodb-runner/package.json

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -27,14 +27,17 @@
2727
},
2828
"license": "Apache-2.0",
2929
"main": "dist/index.js",
30+
"types": "./dist/index.d.ts",
3031
"exports": {
31-
".": {
32-
"require": "./dist/index.js",
33-
"import": "./dist/.esm-wrapper.mjs",
32+
"require": {
33+
"default": "./dist/index.js",
34+
"types": "./dist/index.d.ts"
35+
},
36+
"import": {
37+
"default": "./dist/.esm-wrapper.mjs",
3438
"types": "./dist/index.d.ts"
3539
}
3640
},
37-
"types": "./dist/index.d.ts",
3841
"scripts": {
3942
"bootstrap": "npm run compile",
4043
"prepublishOnly": "npm run compile",

0 commit comments

Comments
 (0)