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

Provide batch_callback_once in Scope #1463

Closed
1 of 3 tasks
ctron opened this issue Aug 2, 2020 · 1 comment · Fixed by #1464
Closed
1 of 3 tasks

Provide batch_callback_once in Scope #1463

ctron opened this issue Aug 2, 2020 · 1 comment · Fixed by #1464
Labels
feature-request A feature request

Comments

@ctron
Copy link
Contributor

ctron commented Aug 2, 2020

Describe the feature you'd like

For the callback method of the Scope struct a method named callback_once exists, which accepts an FnOnce parameter.

I think a similar method (e.g. batch_callback_once) should be provided for the batch_callback function.

Is your feature request related to a problem? Please describe. (Optional)

A closure which gets called only once, makes is easier to move (instead of clone) data. So using a FnOnce would make life easier in some situations.

Describe alternatives you've considered (Optional)

Additional context (Optional)

Questionnaire

  • I'm interested in implementing this myself but don't know where to start
  • I would like to add this feature
  • I don't have time to add this right now, but maybe later
@ctron ctron added the feature-request A feature request label Aug 2, 2020
@siku2
Copy link
Member

siku2 commented Aug 2, 2020

Agreed, since we already have the callback_once method I see no reason why we shouldn't provide the same for batch_callback.

ctron added a commit to ctron/yew that referenced this issue Aug 2, 2020
@ctron ctron mentioned this issue Aug 2, 2020
3 tasks
ctron added a commit to ctron/yew that referenced this issue Aug 2, 2020
ctron added a commit to ctron/yew that referenced this issue Aug 3, 2020
siku2 pushed a commit that referenced this issue Aug 3, 2020
jstarry pushed a commit that referenced this issue Aug 16, 2020
teymour-aldridge pushed a commit to teymour-aldridge/yew that referenced this issue Sep 1, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature-request A feature request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants