I want to load json files only when needed instead of including them in the main bundle. In JS you would do import('./some-file.js') , but in RS I get an error:
external import2: string => Js.Promise.t<array<string>> = "import"
let z = import2("./some-file.js")
// -> [ReScript 106] [W] Unimplemented primitive used:import