Skip to content
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

Use fully qualified syntax in the example of Drawer #187

Merged
merged 10 commits into from
May 7, 2024

Conversation

bioinformatist
Copy link
Contributor

According to rust-lang/rust#48919, a method with this name may be added to the standard library in the future, which may cause ambiguity or even change the behavior. So it would be better to use fully qualified syntax here:

-<Button on_click=Callback::new(move |_| open.call(DrawerPlacement::Top))>"Top"</Button>
+<Button on_click=Callback::new(move |_| leptos::Callable::call(&open, DrawerPlacement::Top))>"Top"</Button>

Also, some clippy lints also have been fixed separately 🍔

@luoxiaozero
Copy link
Collaborator

Thank you, and I would like to add that Callback should solve this problem in leptos0.7. leptos-rs/leptos#2142

@luoxiaozero luoxiaozero merged commit 1865804 into thaw-ui:main May 7, 2024
4 checks passed
@bioinformatist bioinformatist deleted the docs/drawer branch May 8, 2024 02:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants