From 77f5e64100d838cea10bf71b9f86e6768376b1c3 Mon Sep 17 00:00:00 2001 From: Jakub Sys <32591413+MrRefactor@users.noreply.github.com> Date: Tue, 5 Nov 2024 15:01:47 +0100 Subject: [PATCH] fix(ios): Fix adding new page after pager is mounted (#898) --- ios/LEGACY/Fabric/LEGACY_RNCPagerViewComponentView.mm | 1 + 1 file changed, 1 insertion(+) diff --git a/ios/LEGACY/Fabric/LEGACY_RNCPagerViewComponentView.mm b/ios/LEGACY/Fabric/LEGACY_RNCPagerViewComponentView.mm index 7655485a..151e311c 100644 --- a/ios/LEGACY/Fabric/LEGACY_RNCPagerViewComponentView.mm +++ b/ios/LEGACY/Fabric/LEGACY_RNCPagerViewComponentView.mm @@ -94,6 +94,7 @@ - (void)willMoveToSuperview:(UIView *)newSuperview { - (void)mountChildComponentView:(UIView *)childComponentView index:(NSInteger)index { UIViewController *wrapper = [[UIViewController alloc] initWithView:childComponentView]; [_nativeChildrenViewControllers insertObject:wrapper atIndex:index]; + [self goTo:_currentIndex animated:NO]; } - (void)unmountChildComponentView:(UIView *)childComponentView index:(NSInteger)index {