A drop-in standard library for ReScript. Intended to be familiar for JavaScript developers, easy to use, and be rich enough (without being bloated) so that you don't need to reach for anything else for typical ReScript development.
Many JavaScript APIs have methods with trailing optional args and are currently bound in Core as multiple different functions for different argument counts.
However, since ReScript 11, we can have trailing optional args in functions/bindings without needing a () at the end anymore. This allows us to create more idiomatic bindings for such cases, corresponding more closely to the original JS API.
I have already created the following PRs for a some such cases:
198
201
There are quite a few other bindings left that should be changed in a similar way (e.g., Date.make).
For some such functions, the trailing undefineds emitted by the 11.0 compiler for the omitted arguments will be problematic and therefore ReScript 11.1 will be required.
Many JavaScript APIs have methods with trailing optional args and are currently bound in Core as multiple different functions for different argument counts.
However, since ReScript 11, we can have trailing optional args in functions/bindings without needing a
()
at the end anymore. This allows us to create more idiomatic bindings for such cases, corresponding more closely to the original JS API.I have already created the following PRs for a some such cases:
198
201
There are quite a few other bindings left that should be changed in a similar way (e.g.,
Date.make
).For some such functions, the trailing
undefined
s emitted by the 11.0 compiler for the omitted arguments will be problematic and therefore ReScript 11.1 will be required.