ts2ocaml
ts2ocaml copied to clipboard
Generate OCaml bindings from TypeScript definitions via the TypeScript compiler API
Could you provide instructions on how to make it work with the definition files in the playwright repo ? -> https://github.com/microsoft/playwright/tree/main/packages/playwright-core/types Do I need to run the command for just...
Related: #404 To add `playwright` to our automated tests, `ts2ocaml` actually needs to detect `import`s/`require`s of Node's built-in modules and emit module aliases to `rescript-nodejs`'s corresponding ReScript modules.
Related: #396 Symbol indexers are notoriously hard to use from AltJS, but `ts2ocaml` could provide some special support for using them. It depends on the capabilities of `gen_js_api` and the...
Related: https://github.com/rescript-lang/rescript-compiler/issues/6598 We should enable emitting doc comments for recursive modules once ReScript v11.1.0 is released.
Large amount of npm packages are targetting NodeJS, would be awesome to include usable bindings for NodeJS along with those for ES20xx and Dom. They don't need to be OCaml-idiomatic,...
[Minimal repo](https://github.com/mirryi/webextension-polyfill-ocaml) When trying to generate and compile stubs from [`@types/webextension-polyfill`](https://www.npmjs.com/package/@types/webextension-polyfill), I get the following error (using `ts2ocaml 1.4.4`): ``` File "webextension_polyfill.mli", line 26594, characters 10-18: 26594 | module[@js.scope "types"]...
I am currently using ts2ocaml to generate bindings to a fairly large TypeScript library. `ts2ocaml` produces an `mli` file approximately 8.2MB in size, which causes both `ocamlopt` and `ocamlc` to...
Related: https://github.com/ocsigen/ts2ocaml/pull/32#issuecomment-1678472063 ReScript has its own binding for React, and also has a dedicated syntax [`@react.component`](https://rescript-lang.org/docs/react/latest/components-and-props) for React components. ts2ocaml should detect the React components and generate code with the...