React Native 0.72 - Symlink Support, Better Errors, and more
Key Points
- Metro: symlinks & package-exports (beta)
- No redbox for invalid styles; clearer Hermes errors
- Package renames and removed core components; update deps
Summary
React Native 0.72 focuses on developer experience and Metro improvements: beta support for symlinks and package exports, cleaner Metro config loading, better runtime and CLI errors (Hermes improvements), faster Hermes compilation/JSON parsing, and several breaking changes (component removals and package renames). This release also moves New Architecture updates to a dedicated working group.
Key Points
-
Metro
- Beta: symlink support to work with monorepos and pnpm; planned to be enabled by default in 0.73.
- Beta: package-exports support to honor modern package.json export conditions (including the
react-nativecondition). - To enable: set
resolver.unstable_enableSymlinksand/orresolver.unstable_enablePackageExportsinmetro.config.js. - Metro config format changed: update your
metro.config.jsto the new template (0.73 will require it; 0.72 logs a warning).
-
Developer experience
- Invalid StyleSheet properties no longer trigger a redbox; they fail silently like invalid CSS.
- Hermes: clearer error messages (e.g.,
x is not a function (it is undefined)), filtered LogBox stacks, faster large-object compilation and JSON parsing, and new ECMAScript features (prototype.at, well-formed JSON.stringify, AggregateError). - React Native CLI v11: improved CLI error output, less duplication, clearer wording, and links to docs for
init,run-android, andrun-ios.
-
New Architecture
- Updates for the experimental New Architecture are now published through the dedicated working group for more targeted and frequent updates.
-
Breaking changes and migration
- Removed core components: Slider, DatePickerIOS, ProgressViewIOS — migrate to respective community packages (
@react-native-community/*). - Several core-packages were renamed and are now published under the
@react-nativenpm scope (examples:@react-native/eslint-config,@react-native/codegen,@react-native/gradle-plugin). - If you directly depend on renamed packages, update them to their ~0.72 versions when upgrading.
- Removed core components: Slider, DatePickerIOS, ProgressViewIOS — migrate to respective community packages (
Action items for engineers
- Update
metro.config.jsto the new template now to avoid warnings and to ensure CLI tools (likemetro get-dependencies) work. - If you use monorepos/pnpm and want immediate support, enable
resolver.unstable_enableSymlinks(beta) and test thoroughly. - Audit dependencies for renamed packages and removed components; update imports and package versions to the community replacements or
@react-native/*packages. - Use the upgrade-helper and follow upgrade docs; Expo users should watch for support in Expo SDK 49.
Links
- Upgrade helper and upgrade docs (see release notes)
- New Architecture working group for experimental updates