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

Pass form values as a hashmap on oninput/onsubmit #147

Merged
merged 10 commits into from
Feb 5, 2022
Merged

Conversation

jkelleyrtp
Copy link
Member

This PR closes #117 , adding the "values" field to oninput/onsubmit

@jkelleyrtp jkelleyrtp marked this pull request as draft January 22, 2022 20:08
@jkelleyrtp jkelleyrtp marked this pull request as ready for review February 2, 2022 07:01
examples/form.rs Outdated
div {
h1 { "Form" }
form {
oninput: move |ev| println!("{:?}", ev.values),
Copy link
Contributor

@mrxiaozhuox mrxiaozhuox Feb 5, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why use the oninput event? I think there have a special event: onsubmit for form.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just updated to showcase how both onsubmit and oninput support "values"

Copy link
Contributor

@mrxiaozhuox mrxiaozhuox left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice!!

@jkelleyrtp jkelleyrtp merged commit 5383a66 into master Feb 5, 2022
@jkelleyrtp jkelleyrtp deleted the jk/form-ma branch February 8, 2022 05:28
jkelleyrtp added a commit that referenced this pull request Jun 29, 2023
Fix spelling: "inhert" -> "inherit"
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.

event onsubmit field value problem
2 participants