We're excited to release React Native Windows 0.72.0-preview.1 targeting React Native 0.72.0-rc.1. There have been many changes to both react-native-windows and react-native itself, and we would love your feedback on anything that doesn't work as expected. This release includes the commits to React Native Windows from 12/2/2022-3/31/2023.
How to upgrade
You can view the changes made to the default new React Native Windows applications for C++ and C# using React Native Upgrade Helper. See this document for more details.
What's new from React Native Windows
Reliability
- Ensures that, if we are in a XAML Island and we don't have a valid XamlRoot to attach to the ContentDialog, we just treat the alert as dismissed. Fixes issue where Alert crashes (#11168) · microsoft/react-native-windows@340db73 (github.com)
- Suppress auto-focus under certain conditions by forcing the user to first focus the window and update the active XamlRoot via the
XamlUIService::SetXamlRoot
API before a view in the window can get focus. Suppresses auto-focus under certain conditions (#8393) · microsoft/react-native-windows@fecd9a4 (github.com) - Resolve issues in dependency script.rnw-dependencies.ps1 choco typo fix · microsoft/react-native-windows@6bc2353 (github.com), Fix rnw-dependencies.ps1 to run correctly · microsoft/react-native-windows@4228abc (github.com)
- Reduce exceptions being thrown in some normal use cases. Reduce some exceptions being thrown in some normal use cases (#11240) · microsoft/react-native-windows@3bd8471 (github.com)
- Make ETW initialization sequential. Sequentialize ETW init by aeulitz · Pull Request #11255 · microsoft/react-native-windows (github.com)
- Fixes codegen-windows command to successfully run --check command. codegen-windows command run with --check command always fails (#11187) · microsoft/react-native-windows@6a6a622 (github.com)
- Fixes Hermes sampling profiler. Fix Hermes sampling profiler (#11033) · microsoft/react-native-windows@08f6ac5 (github.com)
- Fixes bug where a raw text update clears Text. Fix raw text update clearing Text (#11000) · microsoft/react-native-windows@9e22298 (github.com)
- Ensures NativeAnimatedNodeManager is destroyed on UI thread. Ensure NativeAnimatedNodeManager is destroyed on UI thread (#11169) · microsoft/react-native-windows@952075c (github.com)
- Fixes keyboard event unsubscribe Fix keyboard event unsubscribe (#11057) · microsoft/react-native-windows@5b40a3d (github.com)
- Marks Text dirty when descendant Text updates occur. Mark Text dirty when descendant Text updates occur (#11008) · microsoft/react-native-windows@06245ff (github.com)
- Fixes bug in SvgImageSource where setting RasterizePixelWidth/Height only works the first time it is called. [Image] Fix svg rendering by marlenecota · Pull Request #11009 · microsoft/react-native-windows (github.com)
Accessibility
- Fix backend accessible/focusable adjustment to handle disabled switches. Fix Control Bug Accessible/Focusable Adjustment Code (#11032) · microsoft/react-native-windows@031d0d7 (github.com)
New Features
- Adds BundleAppId to ReactInstanceSettings. Adds BundleAppId to ReactInstanceSettings (#11217) · microsoft/react-native-windows@11f3403 (github.com)
- Add commitid to product version of binaries. Add commitid to product version of binaries (#11316) · microsoft/react-native-windows@87e36a8 (github.com)
- Add submitBehavior prop for TextInput on Paper architecture Add submitBehavior prop to Paper VM for TextInput (#11351) · microsoft/react-native-windows@275b1fb (github.com)
- Add support for
disabled
property for components. Add changes to disabled property for components (e.g TouchableHighlig… · microsoft/react-native-windows@cb93a6c (github.com) - Enriches nativeEvent objects received on JS side in Image onError callback with error message. ReactImage: propagate error messages to JS (#10492) · microsoft/react-native-windows@874960e (github.com)
- Adds the field "rootTag" in NativeDialogManagerWindows and corresponding logic in AlertModule so alerts will show in the proper window when displayed. Adding rootTag so alerts will show in the correct window by helenwxdong · Pull Request #10934 · microsoft/react-native-windows (github.com)
- Implement rowGap, columnGap and gap flex properties. Implement rowGap, columnGap and gap flex properties (#10969) · microsoft/react-native-windows@68fa510 (github.com)
- Adds logic to retain undo/redo history for TextInput. Adds logic to retain undo/redo history for TextInput (#10133) · microsoft/react-native-windows@4c8e547 (github.com)
- Adds collapsible prop for View on Paper architecture. Adds collapsable prop to Paper VM for View (#11249) · microsoft/react-native-windows@7a6f87d (github.com)
Other
- Remove an unneeded force include from yoga/utils.cpp Remove an unneeded force include from yoga/utils.cpp (#11308) · microsoft/react-native-windows@c6842b3 (github.com)
- Move typescript-eslint to devDependencies from Dependencies for several @react-native-windows packages. fix: move typescript-eslint to devDependencies (#11269) · microsoft/react-native-windows@beaa9c1 (github.com)
- LogBox now uses a monospace font. LogBox should be using a monospace font (#11208) · microsoft/react-native-windows@d61980e (github.com)
- Remove the conditional function from BaseViewProps on Windows, which previously conditionally ignored event props. Do not conditionally ignore event props (#11059) · microsoft/react-native-windows@372107f (github.com)
- V8 package update. V8 Package Update (#11027) · microsoft/react-native-windows@2e14e82 (github.com)
- CrashManager now handles SIGABRT. CrashManager: handle abort signal (#11374) · microsoft/react-native-windows@94c6385 (github.com)
Breaking Changes
- Border is now drawn with the default brush if the borderWidth prop is set, not only if a borderColor is also set. (Behavior now matches iOS/Android) Force border with default brush for borderWidth (#11062) · microsoft/react-native-windows@6bb0ecd (github.com)
- Removes deprecated AsynStorage component. Remove AsyncStorage (#10995) · microsoft/react-native-windows@ffef376 (github.com)