We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 0c3b57d commit c2f9684Copy full SHA for c2f9684
Examples/CaseStudies/UIKitCaseStudies/ListsOfState.swift
@@ -61,11 +61,12 @@ final class CountersTableViewController: UITableViewController {
61
}
62
63
override func tableView(_ tableView: UITableView, didSelectRowAt indexPath: IndexPath) {
64
- let counter = self.viewStore.counters[indexPath.row]
+ let indexPathRow = indexPath.row
65
+ let counter = self.viewStore.counters[indexPathRow]
66
self.navigationController?.pushViewController(
67
CounterViewController(
68
store: self.store.scope(
- state: { _ in counter },
69
+ state: \.counters[indexPathRow],
70
action: { .counter(id: counter.id, action: $0) }
71
)
72
),
0 commit comments