Releases: StevenLambion/SwiftDux
Releases · StevenLambion/SwiftDux
v2.0.1
v2.0.0
Deprecated
MappedDispatch
should be replaced with@Environment(.\actionDisaptcher)
to be consistent with Apple's usage. #50MappedState
should be replaced withConnectableView
orConnector
. #50StateType
andIdentifiableState
are deprecated in favor of having applications define their own protocol to adhere to. Instead of requiring an opinionated state type, the library uses conditional protocol adherences when necessary. #50onAction(perform:)
view modifier is deprecated in favor of using middleware. #50
Changes
- macOS 11.0 is now required. #50
- Removed ActionType from the Store<_>'s didChange publisher. #48
Connector
's internal publishing logic has been moved toStateStorable
, so it may be reused elsewhere. #50- All actions may now be chained instead of just ActionPlans. #51
RunnableAction
now returns an AnyPublisher<Action, Never> type instead of anAnyCancellable
. #51ActionPlan
now requires a publisher to return from async blocks instead of providing a completion closure. #52Middleware
now return an optionalAction
instead of callingnext(_:)
on theStoreProxy<_>
. #52
Added
- Added concrete
StorePublisher
in place of using AnyPublisher for store changes. #48 - Added
StateStorable
protocol so that there's a shared way to extend the Store<> and StoreProxy<> types. #50 - Added
StateStorable.publish(_:)
method as a single place to receive an updatable state object. #50
Removed
- StateBinder is removed. #48
- Removed
next(_:)
fromStoreProxy<_>
. #52 - Removed the completion closure from
ActionSubscriber
. #52
Fixed
v1.2.4
v1.2.3
v1.2.1
v1.2.0
Changed
- ActionBinder can now bind actions to callable functions. #40, #38
- Replaced the old internal state connection API with a faster and simpler implementation. #39
Removed
- Removed
Connectable
API in favor of ConnectableView due to incompatibilities with the new internal, reference-free implementation. #39
v1.1.0
Changed
- Loosened the adherence to StateType at the Store level. #36
- Simplified ActionDispatcher API by moving the proxy functionality to OnActionViewModifier. #32
- Provided a more consistent Store API between reducers and middleware. #33
ActionDispatcher
can now be called as a function. #32MappedDispatch
injects an ActionDispatcher instead of a function. #32- Modified the implementation of action plans to make it easier to include 3rd party ones. #36
Added
- Added ActionBinding<> to replace the Equatable extension on Binding<>. #30
Removed
- onAppearAsync and onDisappearAsync. #36
v1.0.1
v1.0.0
This marks the 1.0.0 release of the library. The API will be stabilized moving forward.
Fixed
PersistStateMiddleware
would save the state when theStoreAction<_>.reset
was dispatched. #24- It no longer saves the state when the store is reset.
Connectable.updateWhen
would stop a view from updating from its own dispatched actions. #24- If the method is implemented, both it and any dispatched actions will cause an update.
Connectable.updateWhen
would fail to work in some cases when the first call returned true. #24- Returning true using any possible implementation will now work.
Changed
State
is now required to be equatable. #26Middleware
is now a protocol type. #25StoreProxy.state
is now a non-optional type. #24Store
,ActionDispatcher
, andStatePersistor
no longer adhere toSubscriber
. #24Store.didChange
is now anAnyPublisher<Action, Never>
. #24PersistStateMiddleware
now debounces for 1 second by default. #24PrintActionMiddleware
now accepts a new filter block. #24onAppearAsync
andonDisappearAsync
are deprecated. #24- These were need to workaround a bug in a pervious beta of iOS 13. #24
Added
ActionPlan
has a new init block that accepts an AnyCancellable to supportActionSubsriber
, #24ActionSubscriber
to dispatch actions from a publisher. #24PersistSubscriber
to persist state from a publisher. #24StoreProxy.done
for use in action plans to tell the proxy that it has completed. #24TypedMiddleware
andHandleActionMiddleware
. #25