TypeScript Compiler Options

--help — TypeScript CLI

Prints a compact CLI guide with common invocations and options, then exits without compiling. Use --help --all for the expanded option list. The tested help command does not create JavaScript even when a project exists. Baseline: TypeScript 5.8.3. Commands are run with the pinned local compiler in an isolated directory; omit file labels. CLI-only setting.

Formal Syntax & Structure

typescript syntaxtypescript
tsc --help | tsc -h

Parameters & Attributes

NameTypeDescription
helpbooleanOptional command switch; omit to leave the command inactive.

Working Example

Example Snippettypescript
// File: tsconfig.json (omit this label){  "compilerOptions": {    "target": "ES2022",    "module": "CommonJS",    "strict": true,    "types": [],    "outDir": "dist"  },  "files": [    "index.ts"  ]}// File: index.ts (omit this label)export const count: number = 7;
// Run in a temporary project:// tsc --help
TypeScript Reference