Chris Breuer chris breuer

Home.

A language for JavaScript and TypeScript, built from one Zig toolchain. It is a drop-in replacement for tsc that type-checks your project many times faster, a runtime with Node and Bun built in, and a native language that reads like TypeScript and compiles without a garbage collector. There is no language like Home.

Home is under active development and has no tagged release yet, so for now it builds from source. Then swap the command:

git clone https://github.com/home-lang/home && cd home
pantry install && ./pantry/.bin/zig build

home tsc -p tsconfig.json --noEmit   # instead of npx tsc
home tsc --watch                     # incremental rebuilds
home lsp --stdio                     # one language server for TS and .home
home run server.ts                   # run TypeScript directly

The part most people will meet first. Swap the command and keep everything else: the same tsconfig.json, the same flags, the same TSxxxx diagnostics and the same exit codes.

Home carries Bun's Zig engine on its own JavaScriptCore realm, so the toolchain that checks your TypeScript can also run, test and bundle it. This half is in active development: the core works, and the API surface grows every week.

The other half: .home files that read like TypeScript and compile to native binaries, with no garbage collector and no runtime shipped beside them. The speed of Zig, the safety of Rust, the joy of TypeScript.

One binary, one cache, one set of diagnostics for a repository that mixes both languages.

fn fib(n: int): int {
  if (n <= 1) { return n }
  return fib(n - 1) + fib(n - 2)
}

fn main() {
  let result = fib(10)
  print("Fibonacci(10) = {result}")
}