-
-
Notifications
You must be signed in to change notification settings - Fork 6
Open
Description
Given a package that has exports in its package.json, like this:
{
"exports": {
".": "./dist/index.js",
"./*": {
"types": "./dist/*.d.ts",
"default": "./dist/*.js"
}
}
}When trying to resolve that package, a MODULE_NOT_FOUND error is thrown with "Cannot find module '/path/to/my-package/dist/package.json.js'"
Basically the assumption here that you can always resolve the package.json of a package using node does not hold true anymore in this case. Still I'd like to be able to get the root path of that package, using node module resolution rules. 🤔
Metadata
Metadata
Assignees
Labels
No labels