Socket
Socket
Sign inDemoInstall

clogsjs

Package Overview
Dependencies
1
Maintainers
1
Versions
5
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    clogsjs

Minimalistic NodeJS library for more informative output in the console.log


Version published
Maintainers
1
Install size
4.15 MB
Created

Readme

Source

cLogs.js

author-image NPM version js-image MIT License

logo

Minimalistic NodeJS library for more informative output in the console.log.

cLogs provides three colors for more informative display of logs. You can use:

  • Red - for the most important messages.

  • Green - to notify about completion of work or about a successfully received request.

  • Yellow - for warnings or implicit instructions.

You can also use cLogs without passing an argument. In this case, the output will be the default color of your shell.

cLogs also displays the current date and time using the dependency - moment.js

Installation

Use npm:

npm install clogsjs

Tutorial

Import cLogs into your application:

const cLogs = require('clogsjs');

cLogs('Error! User unavailable', 'red');
cLogs('Success! User sync complete', 'green');
cLogs('Warning! User structure not found', 'yellow');
cLogs('This is just a regular log');

Output:

output.png

License

cLogs.js is freely distributable under the terms of the MIT license.

Keywords

FAQs

Last updated on 21 Dec 2021

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