colored-console-log
A JavaScript API module, which allows app to log colored console logs in browser console.
Installation
Installing this module is pretty easy using npm:
npm install colored-console-log
Then just add the module into your HTML:
In your HTML
<script src="node_modules/colored-console-log/js/colored-console-log.js"></script>
Usage
You can print colored logs in browser console using any of these three functions:
Using colored.logs()
colored;
Using color.logs()
color;
Using cc.logs()
cc;
Customizable / Optional parameters:
colored.logs(Text, Font-color, Background-color)
Parameters
- Text: [String] Message you want to display in console log.
- Font-color: [String][Optional] Font color of text in log, can be HEX value. Default is Black.
- Background-color: [String][Optional] Background color text in log, can be HEX value. Default is White
You can use these function parameters in folowing ways:
colored; color; cc;
License
MIT