Skip to content

Would be nice if submit events exposed the "submitter" element #3195

@bzbarsky

Description

@bzbarsky

See thread starting at https://lists.w3.org/Archives/Public/public-whatwg-archive/2017Oct/0013.html

Properly building the form submission requires knowing the submitter element. See https://html.spec.whatwg.org/#constructing-the-form-data-set and the "submitter" argument it takes.

If someone is trying to do the equivalent from a submit event, they can create a FormData from the form, but there's no way to figure out the submitter element at that point.

Ideally the submit event would expose the submitter element, if any, and the FormData constructor would take it as a second optional argument.

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions