rx_core_observer_fn

Crates.iorx_core_observer_fn
lib.rsrx_core_observer_fn
version0.2.0
created_at2026-01-19 11:26:30.260278+00
updated_at2026-01-24 15:04:00.183995+00
descriptionfn observer for rx_core, it calls a closure
homepagehttps://github.com/AlexAegis/rx_bevy
repositoryhttps://github.com/AlexAegis/rx_bevy
max_upload_size
id2054339
size11,619
Sandor (AlexAegis)

documentation

https://github.com/AlexAegis/rx_bevy

README

observer_fn

crates.io ci codecov license

Define observers from callbacks: FnObserver (static dispatch) and DynFnObserver (dynamic dispatch).

See Also

Example

cargo run -p rx_core --example observer_fn_example
let _subscription = just("world").subscribe(FnObserver::new(
  |next| println!("hello: {next}"),
  |_error| println!("error"),
  || {},
));

Output:

hello: world
Commit count: 652

cargo fmt