-
-
Notifications
You must be signed in to change notification settings - Fork 200
Closed
Description
The option includeNodeModules of bable doesn't work with pnpm, since filePath will contain the real path after resolving the link (for example .../node_modules/.pnpm/plyr@3.6.2/node_modules/plyr/...)
After replacing
const whitelistedModules = options[optionKey].map(
module => path.join('node_modules', module) + path.sep
);
with
const whitelistedModules = options[optionKey].map(
module => path.dirname(require.resolve(module + '/package.json'))
);
it works as expected.
Also the mapping is currently executed for each file again. This could probably done once outside of the callback.
Metadata
Metadata
Assignees
Labels
No labels