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

feat: [#1427] Support submitter in formData constructor and exclude s… #1759

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

karpiuMG
Copy link
Contributor

@karpiuMG karpiuMG commented Mar 1, 2025

…ubmit buttons from formData by default

close #1427

I've checked behavior of formData in Chrome and indeed buttons are not included by default in the formData - that's why existing tests were to change

…d exclude submit buttons from formData by default
@karpiuMG karpiuMG requested a review from capricorn86 as a code owner March 1, 2025 22:03
if (!form) {
return;
}

if (submitter && submitter instanceof HTMLElement) {
Copy link
Owner

Choose a reason for hiding this comment

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

Looking at JSDOM, it seems like it should be implemented a bit different. We will have to look into the spec a bit more.

Link to JSDOM implementation:
https://github.com/jsdom/jsdom/blob/main/lib/jsdom/living/xhr/FormData-impl.js

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.

FormData constructed from a <form> includes buttons by default
2 participants