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

Make use_callback and Callback bring the runtime with them #2852

Merged
merged 3 commits into from
Aug 20, 2024

Conversation

ealmloff
Copy link
Member

We currently have two different callback types: UseCallback and Callback. Both are copy and take arguments, but use_callback keeps the callback up to date with any changes in the origin scope. This PR unifies the two and adds a method to the runtime that wraps a callback with the current runtime

Closes #1905

@ealmloff ealmloff added the hooks Changes to built-in hook package label Aug 16, 2024
@jkelleyrtp jkelleyrtp changed the title Rename use_callback to use_live_callback and add a method to wrap a callback with a runtime Make use_callback and Callback bring the runtime with them Aug 20, 2024
@jkelleyrtp jkelleyrtp merged commit effc0a3 into DioxusLabs:main Aug 20, 2024
15 checks passed
@jkelleyrtp jkelleyrtp added this to the 0.6.0 milestone Aug 20, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
hooks Changes to built-in hook package
Projects
None yet
2 participants