Skip to content
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

fix: move types condition to the front #4698

Merged
merged 1 commit into from May 4, 2023

Conversation

Andarist
Copy link
Contributor

The kind of change this PR does introduce

  • a bug fix
  • a new feature
  • an update to the documentation
  • a code change that improves performance
  • other

I moved types condition to the front. package.json#exports are 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 exports this way so the bug can be fixed in TypeScript.

@Andarist Andarist changed the title fix: move types condition to the front where needed fix: move types condition to the front Apr 29, 2023
@darrachequesne darrachequesne merged commit 3d44aae into socketio:main May 4, 2023
3 checks passed
@darrachequesne
Copy link
Member

Thanks 👍

haneenmahd pushed a commit to haneenmahd/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
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants