-
Notifications
You must be signed in to change notification settings - Fork 11
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Issue interpolating components #184
Comments
With Leptos v0.7 a bunch of things changed so some examples may not compile anymore, I'm sorry for that, I'll try to find the time to update them. You can solve your problem by wrapping #[component]
pub fn TestHtml() -> impl IntoView {
let i18n = use_i18n();
let (counter, _set_counter) = signal(0);
let count = move || counter.get();
let b = |children: ChildrenFn| view! { <b>{move || children()}</b> };
view! {
{/* "click_count": "you clicked <b>{{ count }}</b> times" */}
<p>{t!(i18n, cata.click_count, count, <b>)}</p>
}
} |
By the way, in this exact example you could just do |
Oh, no worries, thank you very much! If I can find some time this week i can create a PR to update them 😄 |
Hello, is this issue solved? If yes can you close it ? |
Hi, I'm using the latest version of the library (v0.5.5), CSR leptos (v0.7.4) and rust nightly and I'm having a bit of an issue when I want to replicate the examples to interpolate html components. Can any one help me see what is wrong?
My code is the following
and I'm using namespaces so the file is
locales/en/cata,json
I get the following error, and it does not go away if I try another option
Even if I force the type
let b = |children: ChildrenFn| view!{ <b>{children}</b> };
returns me a similar error. Any guidance on this will be appreciated since I'm not quite understanding what I'm doing wrong here.The text was updated successfully, but these errors were encountered: