Skip to content

Commit 8e12d08

Browse files
authored
fix!: add "exports" to the package.json (#239)
This commit adds an `"exports"` field to the `package.json` to make self-referencing imports work.
1 parent cae7706 commit 8e12d08

File tree

2 files changed

+4
-1
lines changed

2 files changed

+4
-1
lines changed

package.json

+3
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,9 @@
1212
"engines": {
1313
"node": ">=14.14.0"
1414
},
15+
"exports": {
16+
"./package.json": "./package.json"
17+
},
1518
"license": "MIT",
1619
"packageManager": "yarn@4.0.0-rc.15+sha224.7fa5c1d1875b041cea8fcbf9a364667e398825364bf5c5c8cd5f6601",
1720
"devDependencies": {

tests/_runCli.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ export async function runCli(cwd: PortablePath, argv: Array<string>): Promise<{e
88
return new Promise((resolve, reject) => {
99
if (process.env.RUN_CLI_ID)
1010
(process.env.RUN_CLI_ID as any)++;
11-
const child = spawn(process.execPath, [`--no-warnings`, `-r`, require.resolve(`./recordRequests.js`), require.resolve(`corepack/dist/corepack.js`), ...argv], {
11+
const child = spawn(process.execPath, [`--no-warnings`, `-r`, require.resolve(`./recordRequests.js`), require.resolve(`../dist/corepack.js`), ...argv], {
1212
cwd: npath.fromPortablePath(cwd),
1313
env: process.env,
1414
stdio: `pipe`,

0 commit comments

Comments
 (0)