@@ -33,6 +33,13 @@ Deletes the given search parameter, and its associated value, from the list of a
33
33
@send
34
34
external delete : (urlSearchParams , ~name : string , ~value : string = ?) => unit = "delete"
35
35
36
+ /**
37
+ Returns key/value pairs in the same order as they appear in the query string.
38
+ [Read more on MDN](https://developer.mozilla.org/docs/Web/API/URLSearchParams/entries)
39
+ */
40
+ @send
41
+ external entries : urlSearchParams => Iterator .t <(string , string )> = "entries"
42
+
36
43
/**
37
44
Returns the first value associated to the given search parameter.
38
45
[Read more on MDN](https://developer.mozilla.org/docs/Web/API/URLSearchParams/get)
@@ -54,6 +61,13 @@ Returns a Boolean indicating if such a search parameter exists.
54
61
@send
55
62
external has : (urlSearchParams , ~name : string , ~value : string = ?) => bool = "has"
56
63
64
+ /**
65
+ Returns an iterator allowing iteration through all keys contained in this object.
66
+ [Read more on MDN](https://developer.mozilla.org/docs/Web/API/URLSearchParams/keys)
67
+ */
68
+ @send
69
+ external keys : urlSearchParams => Iterator .t <string > = "keys"
70
+
57
71
/**
58
72
Sets the value associated to a given search parameter to the given value. If there were several values, delete the others.
59
73
[Read more on MDN](https://developer.mozilla.org/docs/Web/API/URLSearchParams/set)
@@ -66,3 +80,17 @@ external set: (urlSearchParams, ~name: string, ~value: string) => unit = "set"
66
80
*/
67
81
@send
68
82
external sort : urlSearchParams => unit = "sort"
83
+
84
+ /**
85
+ Returns the query string suitable for use in a URL, without the question mark.
86
+ [Read more on MDN](https://developer.mozilla.org/docs/Web/API/URLSearchParams/toString)
87
+ */
88
+ @send
89
+ external toString : urlSearchParams => string = "toString"
90
+
91
+ /**
92
+ Returns an iterator allowing iteration through all values contained in this object.
93
+ [Read more on MDN](https://developer.mozilla.org/docs/Web/API/URLSearchParams/values)
94
+ */
95
+ @send
96
+ external values : urlSearchParams => Iterator .t <string > = "values"
0 commit comments