-
Notifications
You must be signed in to change notification settings - Fork 29.8k
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
module: empty fallback and null exports as not exported #32838
Closed
Closed
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
nodejs-github-bot
added
the
esm
Issues and PRs related to the ECMAScript Modules implementation.
label
Apr 14, 2020
guybedford
added
the
modules-agenda
Issues and PRs to discuss during the meetings of the Modules team.
label
Apr 14, 2020
/cc @nodejs/modules-active-members |
jkrems
approved these changes
Apr 14, 2020
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for adding this! It feels more consistent.
From modules team discussion today it seems fine and "we should just do it" |
MylesBorins
removed
the
modules-agenda
Issues and PRs to discuss during the meetings of the Modules team.
label
Apr 22, 2020
guybedford
added a commit
that referenced
this pull request
Apr 22, 2020
PR-URL: #32838 Reviewed-By: Jan Krems <jan.krems@gmail.com>
Landed in e767ed0. |
BethGriggs
pushed a commit
that referenced
this pull request
Apr 27, 2020
PR-URL: #32838 Reviewed-By: Jan Krems <jan.krems@gmail.com>
Merged
BridgeAR
pushed a commit
that referenced
this pull request
Apr 28, 2020
PR-URL: #32838 Reviewed-By: Jan Krems <jan.krems@gmail.com>
Merged
targos
pushed a commit
that referenced
this pull request
Apr 30, 2020
PR-URL: #32838 Reviewed-By: Jan Krems <jan.krems@gmail.com>
targos
pushed a commit
that referenced
this pull request
May 13, 2020
PR-URL: #32838 Reviewed-By: Jan Krems <jan.krems@gmail.com>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR includes two changes to exports edge cases:
"./subpath": []
) to throw ERR_PACKAGE_PATH_NOT_EXPORTED.null
targets ("./subpath": null
) as also throwing ERR_PACKAGE_PATH_NOT_EXPORTED.This comes out of the discussion in jkrems/proposal-pkg-exports#46 where the feature is blacklisting subdirectories via eg:
Both of the above cases would then result in conditional object checks falling through (whereas the current ERR_INVALID_PACKAGE_TARGET for both does not).
There is likely still some discussion to be had here:
[[]]
will throw the same error regardless. So it likely is about what is best for usability and what will more likely match import maps.null
in import maps was originally proposed to match the semantics of[]
, so should likely follow the above.Questions:
null
?[]
follow this same error?I tend to think yes, but let's discuss in the meeting further.
Checklist
make -j4 test
(UNIX), orvcbuild test
(Windows) passes