pub trait Middleware<A: Action> {
// Required methods
fn before(&mut self, action: &A);
fn after(&mut self, action: &A, state_changed: bool);
}Expand description
Middleware trait for intercepting actions
Implement this trait to add logging, persistence, or other cross-cutting concerns to your store.