fix: move types condition to the front#4698
Merged
darrachequesne merged 1 commit intosocketio:mainfrom May 4, 2023
Merged
Conversation
types condition to the front where neededtypes condition to the front
32fa669 to
2a5010d
Compare
Member
|
Thanks 👍 |
verbose117
pushed a commit
to verbose117/socket.io
that referenced
this pull request
May 4, 2023
dzad
pushed a commit
to dzad/socket.io
that referenced
this pull request
May 29, 2023
This was referenced Jun 2, 2024
This was referenced Jun 19, 2024
This was referenced Aug 12, 2024
This was referenced Aug 18, 2024
This was referenced Aug 28, 2024
This was referenced Sep 4, 2024
This file contains hidden or 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
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.
The kind of change this PR does introduce
I moved
typescondition to the front.package.json#exportsare order-sensitive - they are always matched from the top to the bottom. When a match is found then it should be used and no further matching should occur.Right now, the current setup works in TypeScript but it's considered a bug and it should not be relied upon, see the thread and the comment here. For that reason, I would like to fix all popular packages that misconfigured their
exportsthis way so the bug can be fixed in TypeScript.