Navigation with ForEachStore

I'm exploring TCA by creating a small weather app.
This app has an initial List with all user forecast locations (each of the "cells" performs a network request an updates itself to the current forecast). For this I'm using ForEachStore like so:

WithViewStore( { viewStore in
	List {
		        state: { $0.locations }, action: AppAction.weatherForecast(index:action:)
		    id: \.id,
		    content: ForecastPreviewView.init(store:)

How would I go about in the simplest of ways to show another screen with more information about the forecast when the user taps a specific cell? Usually I'd use NavigationLink, but I'm unable to do so because of ForEachStore.

1 Like
Terms of Service

Privacy Policy

Cookie Policy