changelog-cli-logger
v1.0.8
Published
Changelog-style logger for CLIs: ISO timestamps, level icons, and colorized output with zero runtime deps
Maintainers
Readme
changelog-cli-logger
A small TypeScript logger that formats messages like a changelog entry: ISO timestamps, emoji level icons, and optional ANSI colors—handy for command-line tools and local development.
Installation
npm install changelog-cli-loggerUsage
import logger from 'changelog-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 terminals
- 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
