import ComposableArchitecture
The Composable Architecture (TCA, for short) is a library for building applications in a consistent and understandable way, with composition, testing, and ergonomics in mind. It can be used in SwiftUI, UIKit, and more, and on any Apple platform (iOS, macOS, tvOS, and watchOS).
protocol Reducer<State, Action>
A protocol that describes how to evolve the current state of an application to the next state, given an action, and describes what Effect
s should be executed later by the store, if any.
@MainActor init(initialState: @autoclosure () -> State, reducer: () -> some Reducer<State, Action>, withDependencies prepareDependencies: (inout DependencyValues) -> Void = { _ in }, fileID: StaticString = #fileID, file filePath: StaticString = #filePath, line: UInt = #line, column: UInt = #column)
Creates a test store with an initial state and a reducer powering its runtime.