From 8d0d9c200a786f48f7646b00065955e8dca38d28 Mon Sep 17 00:00:00 2001 From: Chris Manson Date: Tue, 31 Oct 2023 15:24:23 +0000 Subject: [PATCH] wip --- packages/reverse-exports/src/index.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/reverse-exports/src/index.ts b/packages/reverse-exports/src/index.ts index e6742d536..5c344bb61 100644 --- a/packages/reverse-exports/src/index.ts +++ b/packages/reverse-exports/src/index.ts @@ -5,7 +5,7 @@ export default function reversePackageExports( relativePath: string ): string { // TODO add an actual matching system and don't just look for the default - if (packageJSON.exports?.['./*'] === './dist/*.js') { + if (packageJSON.exports?.['./*'] === './dist/*.js' || packageJSON.exports?.['./*']?.default === './dist/*.js') { return posix.join(packageJSON.name, relativePath.replace(/^.\/dist\//, `./`).replace(/\.js$/, '')); }