sharletpconsole.js v3.0.2
╭━━━┳╮╱╱╱╱╱╱╭╮╱╱╱╭╮╭━━━┳━━━╮╱╱╱╱╱╱╱╱╱╱╱╭╮
┃╭━╮┃┃╱╱╱╱╱╱┃┃╱╱╭╯╰┫╭━╮┃╭━╮┃╱╱╱╱╱╱╱╱╱╱╱┃┃
┃╰━━┫╰━┳━━┳━┫┃╭━┻╮╭┫╰━╯┃┃╱╰╋━━┳━╮╭━━┳━━┫┃╭━━╮
╰━━╮┃╭╮┃╭╮┃╭┫┃┃┃━┫┃┃╭━━┫┃╱╭┫╭╮┃╭╮┫━━┫╭╮┃┃┃┃━┫
┃╰━╯┃┃┃┃╭╮┃┃┃╰┫┃━┫╰┫┃╱╱┃╰━╯┃╰╯┃┃┃┣━━┃╰╯┃╰┫┃━┫
╰━━━┻╯╰┻╯╰┻╯╰━┻━━┻━┻╯╱╱╰━━━┻━━┻╯╰┻━━┻━━┻━┻━━╯
SharletPConsole.js
A extended version of Node.js Console but with more fancy features! Version: v3.0.2
Table of Contents
Requirements
- Node.js
v12.x
or higher
Getting Started
Prerequisites
There are two ways which you can install: 1. Install using NPM (Recommended)
npm install sharletpconsole.js@v3.0.2 --save
- Install from github
npm install github:sharletp/sharletpconsole.js#v3.0.2 --save
Installation
Please Note: The package internally sets itself as the global console whenever imported/required, please be adviced.
Depending on whether you are using javascript or typescript below are the solutions:
Javascript
const sharletpconsole = require("sharletpconsole.js");
console.log("Hello world!");
Typescript
import { sharletpconsole as console } from "sharletpconsole.js"
console.log("Hello world");
For typescript due to some complexities, you have to follow this.
Usage
Different Premade Console Methods
All of the associated log methods follows this syntax:
Eg: console.log(data, options)
data
- Any: Data to be logged.title
- String: Process title of the current log. Default: process.titlecolor
- String: Color of the log datatype. Default: In-built colordatatype
- String: The type of log. Default: Relative to the method used.The different types of log methods used are:
log, notice, info, warn, alert, critical, emergency, error, debug, debugX
Roadmap
Different premade console log methods- File logging system
- Easy custom log format creation.
Contributing
If you would like to contribute, please do so by creating a pull request for the specific version from the master branch.
Licence
Distributed under the GNU Lesser General Public Licence v3.0.See LICENCE
for more information.
Contact
Name - SharletP Email: sharletman@gmail.com Discord: SharletP#2928
Project Link: https://github.com/sharletp/sharletpconsole.js
Conclusion
I had created this for the sake of simplicity by using pre-made custom console methods and additional features in my projects. Feel free to use it as you'd like to in your own projects and if you do like it, leave a star to show the appreciation.
Best wishes, God bless! 😄