pub fn create_effect<T>(f: impl Fn(Option<T>) -> T + 'static)where
T: Any + 'static,
Expand description
Create an Effect that runs the given function whenever the subscribed Signals in that function are updated.
The given function will be run immediately once and will track all signals that are subscribed in that run. On each subsequent run the list is cleared and then reconstructed based on the Signals that are subscribed during that run.