Closed j00p34 closed 7 months ago
This looks like you have a Leptos version mismatch somewhere. What version of leptos-use do you use and what version of leptos?
leptos-use = "0.10.2" leptos-0.6.5
That should work together shouldn't it? I'm trying to add it to the tailwind_axum example
It should. Maybe try deleting your Cargo.lock and rebuild
Doesn't make a difference, I've uploaded the code here https://github.com/j00p34/tailwind_axum Maybe you can have a look?
Hehe your code is not like you wrote in the error message. Try to change it to exactly that and it works
Yes, you're right thank's a lot. I've been messing around with it to fix that error. But in the code I was using previously I used leptos from a release I downloaded, where cargo was pointing to the local filesystem. I changed that to crates from the internet and I guess that fixed the problem. But I introduced a new error by my messing around. Well thank's a lot again, really appreciate your help.
O'm trying to use use_element_visibility:
But I get the following error:
leptos::web_sys::Element: From<NodeRef<leptos::html::Div>>
is not satisfied --> src/app.rs:28:45From<NodeRef<leptos::html::Div>>
is not implemented forleptos::web_sys::Element
= help: the following other types implement trait>
<leptos::web_sys::Element as From>
<leptos::web_sys::Element as From>
<leptos::web_sys::Element as From>
<leptos::web_sys::Element as From>
<leptos::web_sys::Element as From>
<leptos::web_sys::Element as From>
<leptos::web_sys::Element as From>
and 59 others
= note: required for
| ---------------------- required by a bound in this function
45 | where
46 | El: Into<ElementMaybeSignal<T, web_sys::Element>>,
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in
From<T>
: <leptos::web_sys::Element as FromNodeRef<leptos::html::Div>
to implementInto<leptos::web_sys::Element>
= note: required forElementMaybeSignal<NodeRef<leptos::html::Div>, leptos::web_sys::Element>
to implementFrom<NodeRef<leptos::html::Div>>
= note: 1 redundant requirement hidden = note: required forNodeRef<leptos::html::Div>
to implementInto<ElementMaybeSignal<NodeRef<leptos::html::Div>, leptos::web_sys::Element>>
note: required by a bound inuse_element_visibility
--> /home/timothy/.cargo/registry/src/index.crates.io-6f17d22bba15001f/leptos-use-0.10.2/src/use_element_visibility.rs:46:9 | 44 | pub fn use_element_visibility<El, T>(target: El) -> Signaluse_element_visibility