New Research: Supply Chain Attack on Axios Pulls Malicious Dependency from npm.Details
Socket
Book a DemoSign in
Socket

extended-logger

Package Overview
Dependencies
Maintainers
2
Versions
4
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

extended-logger

Extended logger for nodejs

latest
npmnpm
Version
9007199254740991.9007199254740991.9007199254740988
Version published
Weekly downloads
6
500%
Maintainers
2
Weekly downloads
 
Created
Source

extended-logger

Extend console's log, warn, error, info and assert capabilities.

Usage


  npm i -S extended-logger@9007199254740991.9007199254740991.9007199254740988

  # go to each file where you are console log/error etc...
  require('extended-logger').installConsole(__dirname, __filename)

  # You can use uninstallConsole for uninstalling and going back to older console functions


  const consoler = require('./index')
  console.log('should write a lot more than just this line...') // single line
  consoler.installConsole(__dirname, __filename) // install new console functions
  console.log('should write a lot more than just this line...') // three lines: empty, fancy log, actual message
  consoler.uninstallConsole() // uninstall
  console.log('should write a lot more than just this line...') // back to boring

  /* output */
  // should write a lot more than just this line...
  //
  // [simple.test.js 1505751626284]
  // should write a lot more than just this line...
  // should write a lot more than just this line...

Benefits

  • It tells what function was called: Log, Error, Info etc.
  • It tells you what file it was called from.
  • It tells you what time it was called.

Testing

Just run the simple.test.js file in node

License

MIT © Git Faf 2017 2018

Keywords

console.log

FAQs

Package last updated on 06 Jan 2018

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