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

Compartment mapper should take first matching of conditional exports #2276

Open
kriskowal opened this issue May 8, 2024 · 1 comment · May be fixed by #2275
Open

Compartment mapper should take first matching of conditional exports #2276

kriskowal opened this issue May 8, 2024 · 1 comment · May be fixed by #2275
Assignees
Labels
bug Something isn't working

Comments

@kriskowal
Copy link
Member

Describe the bug

Node.js package conditional imports should take the entries under the first matching tag and ignore all subsequent tags. This is hinted with the express advice that default must appear last if present.

Steps to reproduce

Create a bundle from a package that has conditional exports e.g., endo and default and note that default wins.

Expected behavior

The first match (node in the example) should win.

@kriskowal kriskowal added the bug Something isn't working label May 8, 2024
@kriskowal kriskowal self-assigned this May 8, 2024
@kriskowal
Copy link
Member Author

This fix is necessary for progress toward native XS support #400.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant