File tree Expand file tree Collapse file tree 1 file changed +6
-4
lines changed
Sources/ComposableArchitecture/SwiftUI Expand file tree Collapse file tree 1 file changed +6
-4
lines changed Original file line number Diff line number Diff line change @@ -40,17 +40,19 @@ import SwiftUI
40
40
/// state:
41
41
///
42
42
/// ```swift
43
- /// struct Todos: ReducerProtocol { {
43
+ /// struct Todos: ReducerProtocol {
44
44
/// struct State: Equatable {
45
- /// var todos: IdentifiedArrayOf<TodoState > = []
45
+ /// var todos: IdentifiedArrayOf<Todo.State > = []
46
46
/// }
47
+ /// ...
48
+ /// }
47
49
/// ```
48
50
///
49
51
/// Define a case to handle actions sent to the child domain:
50
52
///
51
53
/// ```swift
52
54
/// enum Action {
53
- /// case todo(id: TodoState. ID, action: TodoAction )
55
+ /// case todo(id: Todo.State. ID, action: Todo.Action )
54
56
/// }
55
57
/// ```
56
58
///
@@ -61,7 +63,7 @@ import SwiftUI
61
63
/// Reduce { state, action in
62
64
/// ...
63
65
/// }
64
- /// .forEach(state: \.todos, action: /Action.todo(id:action:)) {
66
+ /// .forEach(\.todos, action: /Action.todo(id:action:)) {
65
67
/// Todo()
66
68
/// }
67
69
/// }
You can’t perform that action at this time.
0 commit comments