A predictable reactive framework for Rust apps inspired by Redux
Reactor
for arrays of arbitrary length.Reducer
for references, slices, and arrays.SpawnDispatcher
in favor of the more flexible associated function Store::into_task
.<dyn Reactor>::from_sink
and <dyn Dispatcher>::from_sink
in favor of AsyncReactor
and AsyncDispatcher
respectively, both of which can be constructed from any type that implements futures::sink::Sink
.Store
necessarily requires a type that implements Reactor
as the second argument to simplify testing.#70 Added feature alloc
for finer grained control over dependencies.
#76 Generalized Reactor<S>
for dynamically sized types, i.e. S: ?Sized
.
#79 Marked blanket impls of R: Reducer
for [R]
, [R; N]
and &mut R
that have no practical for removal in a future release.
#82 Added Dispatcher::from_sink
that adapts any Sink
into a Dispatcher
.
#85 Added Reactor::from_sink_with
that takes a user defined function Fn(&S) -> O
to adapt any Sink<O>
into a Sink<&S>
.
#81 Refactored SpawnDispatcher
by introducing generic parameters and extracting outputs into associated types. Though code may fail to compile as a result of this, the fix should be trivial boils down to specifying the missing generic parameters.
#85 Store<S, R>
now implements Sink<A>
only if R: Reactor<A> + for<'s> Sink<&'s S>
, where previously it required R: Reactor<A> + Sink<S>
instead and internally cloned &S
into S
. To migrate from the previous version, consider taking advantage of Reactor::from_sink
.
Reactor
for Option
and mpsc::Sender
.Reactor
to always return Result
and to bind to &mut self
.Sink
may now be transformed into a Reactor
using Reactor::from_sink
.futures-rs
(feature async
) is now enabled by default.#[no_std]
environments.Reactor
for Option
and mpsc::Sender
.Reactor
to always return Result
and to bind to &mut self
.Sink
may now be transformed into a Reactor
using Reactor::from_sink
.futures-rs
(feature async
) is now enabled by default.#[no_std]
environments.