tidy-tsc
raw JSON → 0.0.4 verified Fri May 01 auth: no javascript
A CLI tool to clean up and format TypeScript compiler (tsc) output, making it more readable. Version 0.0.4 is the latest stable release, with an active development cadence. It strips redundant information, removes duplicate file paths, and colorizes output. Unlike manual grep or awk scripts, tidy-tsc provides a dedicated, cross-platform solution focused solely on tsc output. Requires Node.js >=22.
Common errors
error tidyt: command not found ↓
cause tidy-tsc is not installed globally or the bin is not in PATH.
fix
Run
npm install -g tidy-tsc to install globally. error Error: Cannot find module 'tidy-tsc' ↓
cause Trying to use `require('tidy-tsc')` as a library; it is a CLI tool only.
fix
Use
npx tidy-tsc or install globally and run tidyt from shell. error No input received (empty) ↓
cause Input is not being piped from tsc.
fix
Ensure you run
tsc | tidyt or tsc | npx tidy-tsc. Warnings
gotcha tidy-tsc expects tsc output piped via stdin; it does not read files or accept file arguments. Ensure you pipe from a `tsc` command. ↓
fix Use pipe syntax: `tsc | tidyt`.
gotcha tidy-tsc does not work with tsc's `--watch` mode output because it expects a one-shot output. Piping from `--watch` may cause unexpected behavior. ↓
fix Do not use tidy-tsc with `--watch`; use it after tsc completes.
deprecated Older versions (<0.0.2) required a separate tsx installation; this dependency was removed in v0.0.2. ↓
fix Upgrade to latest version: `npm install -g tidy-tsc@latest`.
Install
npm install tidy-tsc yarn add tidy-tsc pnpm add tidy-tsc Imports
- tidy-tsc
npm install -g tidy-tsc
Quickstart
#!/usr/bin/env bash
# Example: Run tsc and pipe to tidyt
npx tsc --noEmit --pretty 2>&1 | npx tidy-tsc
# Or if installed globally:
tsc --noEmit --pretty | tidyt