@thanhhoajs/logger
v1.0.5
Published
A powerful and flexible logger designed specifically for the @thanhhoajs ecosystem, optimized for high performance with Bun and TypeScript
Downloads
19
Maintainers
Readme
@thanhhoajs/logger
A powerful and flexible logger designed specifically for the @thanhhoajs ecosystem, optimized for high performance with Bun and TypeScript.
Features
- 🚀 High Performance: Optimized to work blazingly fast with the Bun runtime.
- 🎨 Rich Colors: Supports logging with various colors for easy differentiation of log levels.
- 🔍 TypeScript Ready: Fully written in TypeScript, providing complete type definitions.
- 🔧 Easily Customizable: Flexible for configuration and extension.
- 🧪 Thoroughly Tested: Includes a comprehensive test suite to ensure reliability.
Installation
bun add @thanhhoajs/logger
Usage
import { Logger } from '@thanhhoajs/logger';
const logger = Logger.get('EXAMPLE');
logger.info('Application has started');
logger.warn('This is a warning');
logger.error('An error occurred!');
logger.debug('Debug information');
logger.verbose('Detailed information');
logger.success('Operation successful');
API Overview
info(message: string)
: Log general informationwarn(message: string)
: Log warningserror(message: string)
: Log errorsdebug(message: string)
: Log debug informationverbose(message: string)
: Log detailed informationsuccess(message: string)
: Log success messages
Author
Nguyen Nhu Khanh [email protected]