Skip to content
GuidesDocs 1.3.x

TypeScript ​

Applications can execute erasable TypeScript directly on the documented Node.js line. Connectum packages ship compiled ESM JavaScript and declarations; supported versions and tested Bun behavior are in Runtime Compatibility.

Quick Start ​

bash
# Node.js >=25.2.0 -- run erasable TypeScript directly
node src/index.ts

# Development with auto-reload
node --watch src/index.ts

No loaders, no compilation step, no tsc required to run your code. TypeScript is used for type checking only (tsc --noEmit).

Key Concepts ​

ConstraintRule
No enumUse const objects with as const
No namespaceOnly type-only namespaces allowed
No parameter propertiesUse explicit property declarations
Explicit import typeverbatimModuleSyntax: true
Import extensionsRelative source imports use .ts; generated imports match buf.gen.yaml
node: prefixRequired for Node.js built-in modules

The syntax restrictions follow erasableSyntaxOnly: true: stripping types must leave valid JavaScript. Explicit type imports, import extensions, and the node: prefix are the project's import conventions; the node: prefix is not a TypeScript type-stripping requirement.

Learn More ​