@sapirrior/tscx
v26.0.0
Published
High-performance TypeScript runner using the official compiler with intelligent caching and zero-config support.
Maintainers
Readme
tscx
High-performance TypeScript runner that uses the official TypeScript compiler with intelligent caching and zero-configuration support.
Overview
tscx allows you to run TypeScript files directly from the command line while ensuring full type safety. It intelligently caches compiled output to provide near-instant execution on subsequent runs.
Features
- Pure TypeScript: Uses the official
tscAPI for complete type checking. - Fast Execution: Implements MD5-based caching for optimized performance.
- Zero Configuration: Run standalone
.tsfiles without atsconfig.json. - Dynamic Configuration: Automatically respects local and global configuration files.
- Interactive REPL: Built-in TypeScript shell for testing code snippets.
- Enhanced Diagnostics: Readable, color-coded error reporting with code snippets.
- Environment Support: Integrated
.envfile loading.
Installation
npm install -g @sapirrior/tscxUsage
Run a File
tscx main.tsFast Mode (Skip Type Checking)
tscx --fast main.tsInteractive REPL
tscxLoad Environment Variables
tscx --env-file=.env main.tsDebugging
tscx --inspect main.tsConfiguration
tscx follows a hierarchical configuration model:
- Global:
~/.tscx/tsconfig.json(Auto-generated on first run) - Local: The nearest
tsconfig.jsonto the target file. - Internal Overrides: Critical settings enforced by
tscxfor secure execution.
License
MIT - sapirrior
