Skip to content

Commit 3b7703a

Browse files
committed
fix: - Set every package that still emits CommonJS to declare itself as CommonJS again so bundlers stop loading the build artifacts in ESM mode and hitting exports runtime errors
- Point the few packages whose main/types fields were still referencing the old ./dist paths at the real build outputs instead, so consumers resolve the CJS entry on first try instead of falling through to the broken ESM path
1 parent 9752854 commit 3b7703a

File tree

14 files changed

+3177
-9174
lines changed

14 files changed

+3177
-9174
lines changed

packages/access-control-conditions-schemas/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
"bugs": {
1313
"url": "https://github.com/LIT-Protocol/js-sdk/issues"
1414
},
15-
"type": "module",
15+
"type": "commonjs",
1616
"publishConfig": {
1717
"access": "public",
1818
"directory": "../../dist/packages/access-control-conditions-schemas"

packages/access-control-conditions/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
"bugs": {
1313
"url": "https://github.com/LIT-Protocol/js-sdk/issues"
1414
},
15-
"type": "module",
15+
"type": "commonjs",
1616
"publishConfig": {
1717
"access": "public",
1818
"directory": "../../dist/packages/access-control-conditions"

packages/artillery/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
"name": "@lit-protocol/artillery",
33
"version": "0.0.2-test.0",
44
"private": true,
5-
"type": "module",
5+
"type": "commonjs",
66
"dependencies": {
77
"artillery": "^2.0.23",
88
"@lit-protocol/e2e": "workspace:*"

packages/auth-helpers/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
"bugs": {
1313
"url": "https://github.com/LIT-Protocol/js-sdk/issues"
1414
},
15-
"type": "module",
15+
"type": "commonjs",
1616
"publishConfig": {
1717
"access": "public",
1818
"directory": "../../dist/packages/auth-helpers"

packages/auth-services/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
"name": "@lit-protocol/auth-services",
33
"version": "2.0.1-test.0",
44
"license": "MIT",
5-
"type": "module",
5+
"type": "commonjs",
66
"main": "./src/index.js",
77
"types": "./src/index.d.ts",
88
"publishConfig": {

packages/auth/package.json

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
"bugs": {
1313
"url": "https://github.com/LIT-Protocol/js-sdk/issues"
1414
},
15-
"type": "module",
15+
"type": "commonjs",
1616
"publishConfig": {
1717
"access": "public",
1818
"directory": "../../dist/packages/auth"
@@ -45,7 +45,7 @@
4545
"stream": false
4646
},
4747
"version": "8.0.1-test.0",
48-
"main": "./dist/index.js",
49-
"typings": "./src/index.d.ts",
50-
"types": "./dist/index.d.ts"
48+
"main": "./index.js",
49+
"typings": "./index.d.ts",
50+
"types": "./index.d.ts"
5151
}

packages/constants/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
"bugs": {
1313
"url": "https://github.com/LIT-Protocol/js-sdk/issues"
1414
},
15-
"type": "module",
15+
"type": "commonjs",
1616
"dependencies": {
1717
"@openagenda/verror": "^3.1.4",
1818
"tslib": "^2.8.1",

packages/crypto/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
"bugs": {
1313
"url": "https://github.com/LIT-Protocol/js-sdk/issues"
1414
},
15-
"type": "module",
15+
"type": "commonjs",
1616
"publishConfig": {
1717
"access": "public",
1818
"directory": "../../dist/packages/crypto"

packages/e2e/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
"description": "Lit Protocol E2E testing package for running comprehensive integration tests",
55
"main": "dist/index.js",
66
"module": "dist/index.mjs",
7-
"type": "module",
7+
"type": "commonjs",
88
"types": "dist/index.d.ts",
99
"exports": {
1010
".": {

packages/lit-client/package.json

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
"bugs": {
1313
"url": "https://github.com/LIT-Protocol/js-sdk/issues"
1414
},
15-
"type": "module",
15+
"type": "commonjs",
1616
"publishConfig": {
1717
"access": "public",
1818
"directory": "../../dist/packages/lit-client"
@@ -22,9 +22,9 @@
2222
"universal"
2323
],
2424
"version": "8.0.1-test.0",
25-
"main": "./dist/index.js",
26-
"typings": "./src/index.d.ts",
27-
"types": "./dist/index.d.ts",
25+
"main": "./index.js",
26+
"typings": "./index.d.ts",
27+
"types": "./index.d.ts",
2828
"dependencies": {
2929
"@lit-protocol/uint8arrays": "7.1.1",
3030
"bs58": "^6.0.0",

0 commit comments

Comments
 (0)