Uh oh!
There was an error while loading. Please reload this page.
Breaking: Enable unstable_enablePackageExports by default - #1448
Closed
robhogan wants to merge 1 commit into
Closed
Conversation
facebook-github-botforce-pushed
the
export-D70463018
branch
from
March 3, 2025 16:15
faaf6ac to
77acfaaComparefacebook-github-bot
commented
Mar 3, 2025
Contributor
This pull request was exported from Phabricator. Differential Revision: D70463018 |
facebook-github-bot
commented
Mar 3, 2025
Contributor
This pull request was exported from Phabricator. Differential Revision: D70463018 |
facebook-github-bot pushed a commit
that referenced
this pull request
Mar 3, 2025
Summary: Metro 0.81.3 added support for `package.json#imports` and addressed the main outstanding issue with `package.json#exports` - correct assertion of the `import` or `require` condition. This flips `unstable_enablePackageExports` to `true` ahead of Metro 0.82.0 / RN 0.79-rc.0, which will allow some stabilisation time before this default reaches users. Since this potentially changes the way existing imports are resolved, I'm labelling it semver breaking out of an abundance of caution. I wouldn't expect this to be disruptive, especially because `unstable_enablePackageExports` is already widely enabled in practice. Leaving the flag in place so that anyone who runs into trouble has an escape hatch via `unstable_enablePackageExports: false`. This option will be removed in a later release. Changelog: ``` - **[Breaking]**: Enable support for `package.json#exports` resolution by default. ``` Reviewed By: huntie Differential Revision: D70463018
facebook-github-botforce-pushed
the
export-D70463018
branch
from
March 3, 2025 22:10
ca72506 to
c2fbac7Comparefacebook-github-bot
commented
Mar 3, 2025
Contributor
This pull request was exported from Phabricator. Differential Revision: D70463018 |
Summary: Metro 0.81.3 added support for `package.json#imports` and addressed the main outstanding issue with `package.json#exports` - correct assertion of the `import` or `require` condition. This flips `unstable_enablePackageExports` to `true` ahead of Metro 0.82.0 / RN 0.79-rc.0, which will allow some stabilisation time before this default reaches users. Since this potentially changes the way existing imports are resolved, I'm labelling it semver breaking out of an abundance of caution. I wouldn't expect this to be disruptive, especially because `unstable_enablePackageExports` is already widely enabled in practice. Leaving the flag in place so that anyone who runs into trouble has an escape hatch via `unstable_enablePackageExports: false`. This option will be removed in a later release. Changelog: ``` - **[Breaking]**: Enable support for `package.json#exports` resolution by default. ``` Reviewed By: huntie Differential Revision: D70463018
facebook-github-botforce-pushed
the
export-D70463018
branch
from
March 4, 2025 08:41
c2fbac7 to
c0db98bComparefacebook-github-bot
commented
Mar 4, 2025
Contributor
This pull request was exported from Phabricator. Differential Revision: D70463018 |
facebook-github-bot
commented
Mar 4, 2025
Contributor
This pull request has been merged in 141946c. |
This was referenced Apr 17, 2025
Merged
9 tasks
paschaldev pushed a commit
to paschaldev/metro
that referenced
this pull request
May 25, 2026
paschaldev pushed a commit
to paschaldev/metro
that referenced
this pull request
Aug 15, 2026
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 freeto 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.
Summary:
Metro 0.81.3 added support for
package.json#importsand addressed the main outstanding issue withpackage.json#exports- correct assertion of theimportorrequirecondition.This flips
unstable_enablePackageExportstotrueahead of Metro 0.82.0 / RN 0.79-rc.0, which will allow some stabilisation time before this default reaches users.Since this potentially changes the way existing imports are resolved, I'm labelling it semver breaking out of an abundance of caution. I wouldn't expect this to be disruptive, especially because
unstable_enablePackageExportsis already widely enabled in practice.Leaving the flag in place so that anyone who runs into trouble has an escape hatch via
unstable_enablePackageExports: false. This option will be removed in a later release.Changelog:
Reviewed By: huntie
Differential Revision: D70463018