Closed DevinLeamy closed 2 years ago
I believe this is a bug in the not-stable release. At a glance, the trait requirements for Dispatch::subscribe(...) don't seem to permit the defacto yew Callback<IN> from being used.
Dispatch::subscribe(...)
Callback<IN>
#[derive(Default, PartialEq, Store)] pub struct FrameStore { frame: i32, } impl Component for App { //... fn create(ctx: &Context<Self>) -> Self { let frame_update_callback = ctx.link().callback(Signal::UpdateFrame); let dispatch = Dispatch::<FrameStore>::subscribe(frame_update_callback); // ... } //... }
On another note, just came across this project today - exactly what I was looking for! Thanks!
Turns out the example requires yew = { git = "https://github.com/yewstack/yew.git" }, rather than 0.19.3. 😄
yew = { git = "https://github.com/yewstack/yew.git" }
0.19.3
I believe this is a bug in the not-stable release. At a glance, the trait requirements for
Dispatch::subscribe(...)
don't seem to permit the defacto yewCallback<IN>
from being used.On another note, just came across this project today - exactly what I was looking for! Thanks!