awesome-cli-logger
v1.2.0
Published
Pretty cli logger for CLIs: ISO timestamps, level icons, and colorized output with zero runtime deps
Downloads
568
Maintainers
Readme
awesome-cli-logger
A small TypeScript logger for clis: ISO timestamps, emoji level icons, and optional ANSI colors—aimed at command-line tools and local development.
Installation
npm install awesome-cli-loggerUsage
import logger from 'awesome-cli-logger';
logger.info('Application started');
logger.debug('Debug information', { key: 'value' });
logger.warn('Warning message');
logger.error('Error occurred', new Error('Something went wrong'));
logger.fatal('Fatal error');Log levels
| Level | Purpose |
| ------- | ----------------------- |
| trace | Very detailed tracing |
| debug | Debugging |
| info | General information |
| warn | Warnings |
| error | Errors |
| fatal | Unrecoverable failures |
Features
- Per-level colors in supported clis
- Emoji icons for quick scanning
- ISO-8601 timestamps on each line
- Written in TypeScript with bundled type declarations
- No runtime dependencies beyond Node
License
MIT
