Skip to main content

Module ts

Module ts 

Source
Expand description

TypeScript code generator — rule-based (Tier 2) transpilation from AIR to TS.

Extends the JavaScript codegen with:

  • Type annotations on parameters, return types, and bindings
  • Generics → TS generics (preserved, not erased)
  • Traits → TS interfaces
  • Algebraic types → discriminated union types + tagged objects
  • Type aliases → type X = ...

Structs§

TsGenerator
TypeScript code generator implementing the CodeGenerator trait.