
TypeScript Go
github.com/microsoft/typescript-go- Category
- Developer Tools
- Rank
- No. 2190Tools index
Previous survey · No. 2054 ·
- Type
- APP
- Builder
- microsoft
- GitHub
- 26.2k stars
- Latest release
- typescript/v7.0.2
- Date
About
Microsoft's native port of the TypeScript compiler to Go, targeting major build- and type-checking speedups.
What it does
TypeScript Go runs as a compiler command that reads project configuration, resolves modules and types, reports diagnostics, and emits JavaScript or declarations. It also supports watch mode, project references, incremental builds, JSX, JSDoc, and an emerging editor language service.
Why it's ranked here
This is a compelling preview because the core compiler workflow is already marked complete, including checking, emit, watch mode, and project references. Compatibility targets are explicit against TypeScript 6.0 behavior. However, incomplete editor support and an unready API keep it from being a universal replacement.
What's good
The compatibility claims are unusually concrete: matching source files, syntax errors, resolved types, and diagnostic locations and messages. It handles JavaScript inference, JSDoc, JSX, declaration output, and JavaScript output. Installation fits existing npm workflows, while the command is intended to work like the established TypeScript compiler.
Tradeoffs
The project explicitly remains unfinished, may contain bugs, and lacks full TypeScript feature parity. Some module resolution modes are unsupported, configuration errors may be less helpful, and printed types can differ in diagnostics. The language service remains in progress, while the programmatic API is not ready for use.
How to use it well
Use it to evaluate compiler compatibility on real projects, especially command-line checking, emission, watch workflows, incremental builds, and project references. Keep the established compiler available for comparison and unsupported resolution cases. It does not yet cover teams needing a ready public API or fully completed editor services.
Technical notes+
README.md documents the npm preview package and tsgo CLI, with a later rename to tsc. go.mod declares module github.com/microsoft/typescript-go on Go 1.26. internal/api/server.go exposes a server over stdio, Unix domain sockets, or Windows named pipes, selecting synchronous MessagePack or asynchronous JSON-RPC. internal/api/proto.go defines methods for snapshots, symbols, types, diagnostics, emission, references, completions, and profiling. internal/api/session.go scopes symbol registries to snapshots and type and signature registries to projects. internal/api/callbackfs.go can delegate selected filesystem operations to an RPC client. internal/lsp/server.go contains the separate language-server implementation.
Observed
- License
- Apache-2.0
- Primary language
- Go, with Node and TypeScript development tooling
- Installation surface
- npm preview package @typescript/native-preview
- Command-line interface
- Installed preview runs through tsgo; TypeScript 7.0 RC and later use tsc
- Editor interface
- Preview VS Code extension and an in-progress LSP language service
- Programmatic interface
- Bidirectional RPC infrastructure exists, but the README marks the API not ready
- Transport support
- Standard input and output, Unix domain sockets, and Windows named pipes
- Workspace structure
- Private npm workspace covering extension and package workspaces
Read from README.md, go.mod, package.json, internal/ast/ast.go, internal/api/conn.go, internal/api/proto.go, internal/api/server.go, internal/lsp/server.go, internal/api/timing.go, internal/api/session.go, internal/api/protocol.go, internal/api/conn_sync.go, internal/api/transport.go, internal/api/callbackfs.go, internal/api/conn_async.go.
Tech Stack
Comments (0)
No comments yet
Editorially curated, with community endorsements as a secondary signal. Corrections welcome.