fix: reorder 'default' export condition to the end for compatibility #1317
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 addresses an issue with the
package.json
where thedefault
export condition was not listed as the final entry in theexports
field. While the ECMAScript specification indicates that object keys are unordered, some build tools have come to rely on the order of export conditions to function correctly. By moving thedefault
condition to the last position, we can improve the compatibility of this package with a wider variety of build tools and environments that may depend on this ordering.Changes made:
default
export condition within the.exports
field ofpackage.json
to appear last for bothimport
andrequire
conditions.Benefits:
exports
field.package.json
.Please review the changes and merge this PR if everything is in order. Thank you for considering this improvement to the package's build tool compatibility.