Insert temporary input node to polyfill submitter argument in FormData (#26714)

Summary:
Insert temporary input node to polyfill submitter argument in FormData.
This works for buttons too and fixes a bug where the type attribute
wasn't reset.

I also exclude the submitter if it's a function action. This ensures
that we don't include the generated "name" when the action is a server
action. Conceptually that name doesn't exist.

DiffTrain build for commit https://github.com/facebook/react/commit/5e5342b10059bf90738a8d9171fcf0af9d9d5d51.

Changelog: [Internal]

Reviewed By: kassens

Differential Revision: D45240323

fbshipit-source-id: 3e9a8076942abdc24cf25b9dd9f130727ec3c0fd
This commit is contained in:
sebmarkbage
2023-04-25 11:43:52 -07:00
committed by Facebook GitHub Bot
parent 1b41b54897
commit bfeef95c44
@@ -1 +1 @@
9c58a0b6475509f9124da578207aa0d3b7364035
5e5342b10059bf90738a8d9171fcf0af9d9d5d51