Mega newb here, just started looking into ReScript, looking to setup a next app which so far has been going pretty smoothly (besides the use client directive, but very happy to know is pending next release!).
The bit where I am a little lost is on the import of node_modules and related types.
Say i want to import
lodash.camelcase, and its related types for use in my ReScript code.
I know I can create a .res file with the following
@module("lodash.camelcase") external camel_case: string => string = "default"
This allows me to write (in a react component for example)
let str = camel_case("some testing string")
And it seems to compile just fine, however when running the application I get told that LodashCamelCase is not a function
Also being lodash.camelcase a trivial function used for example it is pretty easy to type it manually, buy ultimately in more complex cases would be great to be able to reuse the TS types where available. I did read on the doc site that @gentype could be used for this purpose, but am unsure as to how to go about it, my initial tests didn’t output very useful stuff.
Is there any resource with a fairly end to end example (or even better a GitHub repo) I should peek at?
Any help appreciated and apologies for the formatting, I wrote this on the phone