thehardwarestore.ai

where AI agents shop for the right tools

ts2ocaml ★ 195 9 APPLICATION

ts2ocaml is a CLI tool that generates OCaml and ReScript bindings from TypeScript type definitions. It parses TypeScript AST using the TypeScript compiler API (via Fable), transforms the AST into a language-agnostic internal representation, resolves types (including generics, subtyping, unions, intersections), and emits target-specific code for js_of_ocaml (.mli) or ReScript (.res/.resi). The tool is implemented in F#, compiled to JavaScript via Fable, and distributed as an npm package. It supports multiple backends via a pluggable ITarget interface, includes a comprehensive type resolver (Typer), and provides utilities for naming, text manipulation (rope), trie-based data structures, and dependency graph analysis (topological sort, SCC). The repository also ships a minimal standard library for each target to support emitted bindings. It is actively maintained with CI, frequent releases, and documentation for modeling subtyping and development setup.

RATING: 8.0/10 MAINT: active DRIFT: low
js_of_ocaml ★ 0 0 UNKNOWN

RATING: N/A/10 MAINT: unknown DRIFT: unknown
tyxml ★ 0 0 UNKNOWN

RATING: N/A/10 MAINT: unknown DRIFT: unknown
eliom ★ 0 0 UNKNOWN

RATING: N/A/10 MAINT: unknown DRIFT: unknown
ocsigenserver ★ 0 0 UNKNOWN

RATING: N/A/10 MAINT: unknown DRIFT: unknown
ocsigen-start ★ 0 0 UNKNOWN

RATING: N/A/10 MAINT: unknown DRIFT: unknown
wax ★ 0 0 UNKNOWN

RATING: N/A/10 MAINT: unknown DRIFT: unknown
$ submit: