This package has been deprecated

    Author message:

    deprecated

    @bucuo/logger

    0.0.5 • Public • Published

    Logger

    Simple JSON logger.

    Install

    npm install @bucuo/logger

    Usage

    const { logger } = require("@bucuo/logger");
     
    logger.$level(msg, err, det);

    Args are classified by types. You can pass in args in any order.

    Arg Types

    • msg: string
    • err: Error or Object with string fields name, message and stack
    • det: plain Object

    Default Levels

    • 60: fatal
    • 50: error
    • 40: warn
    • 30: info
    • 20: debug
    • 10: verbose

    Default Options

    see Default Options

    Env Options

    • LOG_PRINT_LEVEL: number
    • LOG_PRINT_PRETTY: boolean
    • LOG_ENABLE_TS: boolean
    • LOG_ENABLE_TSS: boolean

    Advanced

    If you are not satisfied with the default logger and env options, you could build logger with pre-defined or customized bricks.

    See

    License

    MIT

    Install

    npm i @bucuo/logger

    DownloadsWeekly Downloads

    1

    Version

    0.0.5

    License

    MIT

    Unpacked Size

    9.3 kB

    Total Files

    13

    Last publish

    Collaborators

    • zhaoyao91