@xtx1130/tb-log

2.0.1 • Public • Published

tb-log

A simple log for node cli

Build Status Coverage Status

pic

Install

$  npm install @xtx1130/tb-log

Usage

const log = require('@xtx1130/tb-log') // will use the defalut name: tb

log.warn('test')

or

const Log = require('@xtx1130/tb-log').Log
const log = new Log('name', true)

log.success('test')

API

class Log

const Log = require('@xtx1130/tb-log').Log
const log = new Log('name', true)

args[0] <String> The name will show on the tty
args[1] <Boolean> Async console or not(sync console,use fs.writeSync)

log.error(str)/success/info/start/warn/default

log.error('test')

log.clear()

log.clear()

clear ttys

License

MIT

Readme

Keywords

Package Sidebar

Install

npm i @xtx1130/tb-log

Weekly Downloads

0

Version

2.0.1

License

MIT

Unpacked Size

7.13 kB

Total Files

12

Last publish

Collaborators

  • xtx1130