Socket
Socket
Sign inDemoInstall

nice-logs

Package Overview
Dependencies
0
Maintainers
1
Versions
2
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    nice-logs

Pretty console logs.


Version published
Weekly downloads
3
Maintainers
1
Created
Weekly downloads
 

Readme

Source

Nice Logs

Website

A pretty nice, colorful and lightweight console log for the browser. Prints a line with log type and high resolution time stamp. With integrated TypeScript type definitions.

Install

npm i nice-logs

NPM Package

Usage

Log.title('This is a title log.');
Log.info('This is an info message.');
Log.warn('This is a warn message.');
Log.error('This is an error message.');
Log.success('This is a success message.');

// How to replace `console.log(...)`?
Log.info('...');

// Just log time.
Log.info();

// Do not log time.
Log.timeStampEnabled = false;
Log.info('No time stamp here.');

// I want to use own style. (Experimental)
Log.logStyle.info = 'color: blue';
Log.modeText.info = 'LOL';
Log.info('Hehe');

Troubleshoot

This should work with all Chromium browsers like Chrome, Opera and the "new" Edge browser. (The Edge with Chromium. The old one does not support it.) It also works with Firefox. Not tested in Safari. NodeJS is not supported. Maybe in the future.

Keywords

FAQs

Last updated on 25 Jan 2020

Did you know?

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

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc