Skip to content

Commit e016366

Browse files
authored
Merge pull request #108 from mvaled/add-binding-FormData-fromForm
Add new binding to Webapi.FormData to create it from form elements.
2 parents 1a64769 + 30d8635 commit e016366

File tree

2 files changed

+4
-0
lines changed

2 files changed

+4
-0
lines changed

CHANGELOG.md

+2
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,8 @@
4242
* CustomEvent Functor to make custom events with strongly typed `detail` fields (#93)
4343
* `Webapi.Url.createObjectURLFromBlob` binding that takes a `Webapi.Blob.t` (#106)
4444
* `returnValue` setter for `BeforeUnloadEvent` (#110)
45+
* `Webapi.FormData.makeWithHtmlForm` binding that takes a `Webapi.Dom.HtmlFormElement.t` (#108)
46+
4547

4648
### Fixed
4749
* `ofElement` was incorrectly returning `Dom.htmlElement` type instead of the enclosing element type (#60)

src/Webapi/Webapi__FormData.res

+2
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,8 @@ module EntryValue = {
1212
type t
1313

1414
@new external make: unit => t = "FormData"
15+
@new external makeWithHtmlForm: Webapi__Dom__HtmlFormElement.t => t = "FormData"
16+
1517
@send external append: (t, string, string) => unit = "append"
1618
@send external delete: (t, string) => unit = "delete"
1719
@send external get: (t, string) => option<EntryValue.t> = "get"

0 commit comments

Comments
 (0)