-
-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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
Better error message for exports
-only packages
#2352
Comments
"might not be added" is objectively false; it absolutely will be added, with 100% certainty. The only unknown is the timeframe. I have stated as such (the word "yet" is important) in all of those issues you linked. I'm not sure what better error message would be possible without actually having support in the first place. |
Sorry for misunderstanding, I guess "it’s designed for use with CJS" left this impression on me. Naively I would have tried, whenever the |
I suppose that's something the node resolver could try to do, in the event that |
If you're using typescript, you should be using that resolver regardless - and if not, you likely shouldn't be either. |
I have seen in several places here (#2293, #2331, #2319 (comment)) that the support for
exports
-only dependencies is missing, and might not be added. The error messageUnable to resolve path to module 'got'.
does not do a good job to explain that. Would it be possible to handle this case better by providing a custom error message?It would also be nice to have the project’s position on such dependencies to be explicitly stated somewhere in readme, or the support for it tracked in some "official" issue.
The text was updated successfully, but these errors were encountered: