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 enter key on a form input trigger click on first submit button #66

Open
wants to merge 1 commit into
base: master
from

Conversation

Projects
None yet
2 participants
@dkordik

dkordik commented Sep 19, 2014

When you press enter on an input inside of a form, the browser fires a submit event on the form, and also fires a click event on the first submit button of the form, if there is one. elements default to type "submit" if a type is not specified.

This behavior is illustrated in this jsfiddle: http://jsfiddle.net/dkordik/y25r4qnp/

Closes #65

Make enter key on a form input trigger click on first submit button
When you press enter on an input inside of a form, the browser fires a submit event on the form, and also fires a click event on the first submit button of the form, if there is one. <button> elements default to type "submit" if a type is not specified.

This behavior is illustrated in this jsfiddle: http://jsfiddle.net/dkordik/y25r4qnp/

Closes #65
@justinbmeyer

This comment has been minimized.

Member

justinbmeyer commented Sep 19, 2014

Wow ... I was not aware of that. Good catch!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment