You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have been trying to implement a native search bar (equivalent to .searchable) on top of this library, but I've hit a significant architectural roadblock due to the SwiftUI implementation.
The Discovery: To implement the native search bar in SwiftUI, the view must be wrapped in a NavigationStack (or NavigationView). Without it, the .searchable modifier does nothing.
The Problem: When I wrap the tabs in a NavigationStack to enable search, it introduces a "Nested Navigation Stack" scenario. Since many apps (especially those using react-native-screens or hybrid native apps) already have a root Navigation Controller, adding this internal NavigationStack causes:
Crashes when navigating between the tab and other native screens.
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
-
I have been trying to implement a native search bar (equivalent to .searchable) on top of this library, but I've hit a significant architectural roadblock due to the SwiftUI implementation.
The Discovery: To implement the native search bar in SwiftUI, the view must be wrapped in a NavigationStack (or NavigationView). Without it, the .searchable modifier does nothing.
The Problem: When I wrap the tabs in a NavigationStack to enable search, it introduces a "Nested Navigation Stack" scenario. Since many apps (especially those using react-native-screens or hybrid native apps) already have a root Navigation Controller, adding this internal NavigationStack causes:
Crashes when navigating between the tab and other native screens.
Double Navigation Bars or layout glitches.
Broken Interactive Pop Gestures.
Beta Was this translation helpful? Give feedback.
All reactions