Socket
Book a DemoInstallSign in
Socket

appcan-logger

Package Overview
Dependencies
Maintainers
1
Versions
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

appcan-logger

日志操作

1.0.0
latest
Source
npmnpm
Version published
Weekly downloads
0
-100%
Maintainers
1
Weekly downloads
 
Created
Source

logger

简单的日志操作

安装部署

npm install appcan-logger

使用

var logger = require("appcan-logger")('[app]'); logger.error('hello world'); logger.warn('hello world'); logger.info('hello world'); logger.log('hello world');

##日志等级 'all', 'debug', 'info', 'warn', 'error', 'fatal', 'off' 分别对应着1-7等级

设置日志等级(只对设置后的日志起作用) require("appcan-logger").setLevel(4);

清空日志(所有日志不输出,只对设置后的日志起作用) require("appcan-logger").clear();

推荐使用等级
'debug', 'info', 'warn', 'error'

默认debug等级

Keywords

node

FAQs

Package last updated on 25 Dec 2015

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

About

Packages

Stay in touch

Get open source security insights delivered straight into your inbox.

  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc

U.S. Patent No. 12,346,443 & 12,314,394. Other pending.