Directory Compare FCRS-1.0 /llms.txt
← Back to Directory

TypeScript Compiler

$ tsc Official Low Risk
Microsoft · Code & DevOps · Apache-2.0 · macos / linux / windows

Official CLI for Microsoft TypeScript providing static type-checking (--noEmit), composite project builds (--build --dry), resolved JSON config inspection (--showConfig), and color-free diagnostics (--pretty false). Essential verification gate for TypeScript repositories.

FCRS-1.0 Score
88 /100
Good
Medium Confidence
Zero-Friction Install
npm install -g typescript
CLI vs MCP Decision CLI Only

Runs local TypeScript type-checking directly against workspace tsconfig.json and node_modules types.

Agent-Readiness Checklist

✓ JSON Output
— Field Filtering
✓ Non-Interactive
✓ Dry-Run
✓ Read-Only Mode
✓ NO_COLOR Clean
✓ Self-Describing
— Official SKILL.md

Static evaluation (not yet probed on this host). Run npm run data:probe locally to capture live verification.

FCRS-1.0 6-Dimension Breakdown

Agent-Readiness 20 / 25

Supports --noEmit, --pretty false, --build --dry, --listFilesOnly, and JSON --showConfig, though type errors themselves are formatted text rather than JSON.

  • --noEmit and --pretty false provide clean non-TTY checks
  • --showConfig outputs JSON and --build --dry previews builds
Trust & Safety 23 / 25

--noEmit and --build --dry guarantee zero file writes and zero network/credential side effects.

  • Read-only verification via --noEmit
Setup & Portability 14 / 15

Available everywhere Node.js runs via project devDependencies, npx, or global npm install.

  • Standard npm package across macOS, Linux, and Windows
Utility & Efficiency 13 / 15

Authoritative static type-checker for TypeScript codebases, catching interface mismatches before runtime.

  • Canonical type-checker matching TypeScript language semantics
Maintenance & Lineage 10 / 10

First-party Microsoft compiler (microsoft/TypeScript) under Apache-2.0.

  • Official microsoft/TypeScript repository
Docs & Verifiability 8 / 10

Complete compiler flag handbook and --help / --all option listing.

  • Official documentation at typescriptlang.org

Security, Auth & Guardrails

Auth Modes
No Auth
Credential Storage

No credentials required; operates strictly on local .ts/.tsx source files and tsconfig.json.

Side Effects
Read-Only Local Write
Cost & Quotas

Apache-2.0 open-source CLI; completely free.

Copyable Guardrail for CLAUDE.md / AGENTS.md
# TypeScript Compiler (tsc) Agent Rules
- Always run `tsc --noEmit --pretty false` (or `npx tsc --noEmit --pretty false`) to verify TypeScript edits cleanly.
- Use `tsc --showConfig` to inspect inherited `tsconfig.json` settings instead of guessing compiler flags.

Agent-Ready Command Recipes

Safe Read-Only Queries

Type-check project without emitting JavaScript files
tsc --noEmit --pretty false

Runs full static type-checking in read-only mode with clean, color-free file:line:col errors.

Print resolved tsconfig.json as JSON
tsc --showConfig

Outputs the final merged tsconfig.json (including extends) in JSON without compiling.

Controlled Writes & Previews

Preview composite project reference build plan
tsc --build --dry

Shows which composite sub-projects are out of date without writing .js or .tsbuildinfo files.

Strengths for Agents

  • + tsc --noEmit --pretty false is the gold-standard read-only type-check gate for TS projects.
  • + --showConfig outputs resolved tsconfig.json JSON and --build --dry previews monorepo builds.

Caveats & Pitfalls

  • ! Type error diagnostics are emitted as formatted text lines rather than a --json array.
  • ! Large monorepos can consume high RAM/CPU unless scoped with project references (tsc -b).

Tested Agent Hosts

Claude Code Codex CLI Gemini CLI