Files
react-native/packages/react-native
Christian FalchandFabrizio Cucci d59159df17 fix adding children (#51213)
Summary:
See https://github.com/facebook/react-native/issues/51212 - children aren't updated correctly in an old arch native view using the interop layer under Fabric.

This is caused by the mountChildComponentView method not updating the view, only adding the new view to a list that will be used on the next update to mount the child.

This commit fixes this by adding the same pattern as in unmountChildComponentView where children are inserted directly if the underlying paperview is available in the adapter - otherwise it uses the mounting list as before.

#Closes 51212

bypass-github-export-checks

## Changelog:

[IOS] [FIXED] - fixed adding child views to a native view using the interop layer

Pull Request resolved: https://github.com/facebook/react-native/pull/51213

Test Plan:
**Previous output**:

<image src="https://github.com/user-attachments/assets/472b95e7-0921-46c9-be6a-f31759c0cd26" width="200px" />

**After fix**:

<image src="https://github.com/user-attachments/assets/554387cd-c264-483e-9c52-d9cd40b42601" width="200px" />

Reviewed By: sammy-SC

Differential Revision: D74471278

Pulled By: cipolleschi

fbshipit-source-id: 798f9e7be389359bd6e3aa1b6a6e9fb799fcb369
2025-07-09 11:32:36 +01:00
..
2025-01-10 07:38:19 -08:00
2025-04-01 12:57:44 +00:00
2025-07-09 11:32:36 +01:00
2025-04-01 12:57:44 +00:00
2025-04-01 12:57:44 +00:00
2025-01-13 15:57:54 +01:00
2025-04-01 12:57:44 +00:00

Where is the template?

The React Native Template has moved from being shipping inside the react-native package to it's own package: @react-native-community/template.

Why has it moved?

The React Native Frameworks RFC0759 provides background information.

When was it moved?

The 0.75 release.