Documentation - v0.0.10
    Preparing search index...

    Function createBaseLogger

    • Creates a base logger function that logs messages to the console with a timestamp and context. The logger supports different severity levels: 'info', 'warn', 'error', and 'debug'.

      Parameters

      • context: string

      Returns Logger

      const logger = createBaseLogger('MyApp');
      logger('info', 'This is an informational message.');

      // Console output:
      // [12:34:56] [MyApp] This is an informational message.