You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have followed this tutorial to debug state variables using gloo, as follows:
let features = use_state(|| vec![]);// Do something on featureslog!(features)
However, I am getting this error:
error[E0277]: the trait bound `JsValue:From<yew::UseStateHandle<Vec<Feature>>>` is not satisfied
--> src/components/banner.rs:32:8
|
32 | log!(features);
| -----^^^^^^^^-
| | |
| | the trait `From<yew::UseStateHandle<Vec<Feature>>>` is not implemented for `JsValue`
| required by a bound introduced by this call
|
= help: the following other types implement trait `From<T>`:
<JsValueasFrom<&'a T>>
<JsValueasFrom<&'a std::string::String>>
<JsValueasFrom<&'a str>>
<JsValueasFrom<*constT>>
<JsValueasFrom<*mutT>>
<JsValueasFrom<AbortSignal>>
<JsValueasFrom<AddEventListenerOptions>>
<JsValueasFrom<AnimationEvent>>
and 148 others
For more information about this error, try `rustc --explain E0277`.
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
I have followed this tutorial to debug state variables using
gloo
, as follows:However, I am getting this error:
Also, tried:
But, it didn't work either.
Beta Was this translation helpful? Give feedback.
All reactions