Negligible Psychological Misery

    @webpart/console

    2.1.1 • Public • Published

    @webpart/console

    在原生 console 的基础上增加输出日志到指定文件里的功能。

    npm install @webpart/console

    let console = require('@webpart/console');
    
    console.file = './output/console.log';
    
    console.log('a', 'b', 'c');
    console.log({ a: 1, b: 2, });
    console.log(new Date());
    console.log(new Error('test-error'));
    console.log([1, 2, 3]);
    console.log(NaN);
    console.log(undefined);
    console.log(null);
    console.error('error--ABC');
    
    
    

    Keywords

    none

    Install

    npm i @webpart/console

    DownloadsWeekly Downloads

    2

    Version

    2.1.1

    License

    MIT

    Unpacked Size

    11.2 kB

    Total Files

    8

    Last publish

    Collaborators

    • micty