NavigationSplitView usage with TCA's current (1.23.1) version #3826
OddMagnet
started this conversation in
Show and tell
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Hey everyone, I recently tried to figure out how to use a
NavigationSplitViewin TCA.I wasn't able to find any minimal up to date example, so after some trial and error I was able to make my own example.
With this discussion I'm hoping for 2 things:
Link to the example repository with a longer explanation in the README
https://github.com/OddMagnet/NavigationSplitView-TCA-Example
TL;Didn't Click:
AppReducerholds the state for theSidebar,ContentandDetailreducers. When an entry in theSidebarView/ContentViewis selected theAppReducercreates theContent/Detailreducer's state.The
NavigationSplitViewholdsSidebarView,ContentViewandDetailView.SidebarViewandContentViewboth haveList(selection:content)'s withNavigationlink(value:label). When a selection is made SwiftUI automatically shows the next column's view.Beta Was this translation helpful? Give feedback.
All reactions