JSPM

  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 255
  • Score
    100M100P100Q91521F
  • License MIT

Package Exports

    Readme

    @o2s/utils.logger

    Winston-based logging utility for O2S applications with NestJS integration.

    Installation

    npm install @o2s/utils.logger

    Usage

    NestJS Integration

    Register the logger module in your app.module.ts:

    import { LoggerModule } from '@o2s/utils.logger';
    
    @Module({
        imports: [LoggerModule],
    })
    export class AppModule {}

    Using Logger Service

    import { LoggerService } from '@o2s/utils.logger';
    
    @Injectable()
    export class MyService {
        constructor(private readonly logger: LoggerService) {}
    
        doSomething() {
            this.logger.log('Info message');
            this.logger.warn('Warning message');
            this.logger.error('Error message', error);
        }
    }

    Features

    • Winston-based logging
    • NestJS integration
    • Structured logging
    • Log levels (error, warn, info, debug)

    Peer Dependencies

    • @nestjs/common ^11.0.16
    • @nestjs/core ^11
    • @nestjs/config ^4.0.2
    • @nestjs/axios ^4.0.1
    • rxjs ^7
    • @o2s/framework - Core framework