Object.fromEntries
is bound by both Dict.fromArray
and Dict.fromIterator
.
About FormData
, there is a fairly recent thread: Using FormData in rescript react, but I agree it should be easier to find and rescript-webapi could be modernized.
The _
makes the type system allow any type. It’s similar to 'a
, but it also works for multiple arguments as long as they are all generic.
Example:
type props<'a, 'b, 'c> = {a: 'a, b: 'b, c: 'c}
let make = ({a, b}: props<_>) => Console.log2(a, b)