-
Notifications
You must be signed in to change notification settings - Fork 19
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
esmock 1.9.1 and eslint: Unable to resolve path to module 'esmock' #106
Comments
@tripodsan I apologize for breaking this. The PR you made has been published. |
it's just that plugin does not support related: import-js/eslint-plugin-import#2495 |
yes, but also I'm not sure that the exports are correct this way:
@iambumblehead , what was the intention of those? if you look at the nodejs doc, all sub-package exports usually start with a
would make more sense. |
I think it's working as expected, it's the same as: "exports": {
".": {
"import": "./src/esmockLoader.js",
"types": "./src/esmock.d.ts"
}
}, |
ah right, those are conditional exports |
The pattern was changed in order to ensure support with newer versions of typescript. I accidentally removed too many fields and, to catch issues in the future, I'll try requesting reviews. The export pattern is seen here https://nodejs.org/api/packages.html#approach-2-isolate-state and the pattern was recommended here iambumblehead/form-urlencoded#45 The Anyway, I will need to study export patterns to learn more about them and to support them at esmock's resolver https://github.com/iambumblehead/resolvewithplus (for which the unit-tests were re-organized a day or two ago, in preparation for the unit-tests that would need to be added) |
would one of you review my PR here? iambumblehead/resolvewithplus#24 |
With 1.9.1 I get:
the problem are the
exports
added in: 96d2754also see:
https://nodejs.org/docs/latest-v16.x/api/packages.html#package-entry-points
when I add the
again, it works.
The text was updated successfully, but these errors were encountered: