Code Monkey home page Code Monkey logo

disjs-logger's Introduction

Disjs Logger



NPM Banner



๐Ÿ“œ Usage

const logger = require('disjs-logger');
const console = new logger('C:\\Users\\Username\\ProjectDirectory\\logfile.txt');
// Double back slashes are used as single back slashes are escape chars
console.log("My error here", "error", __filename, `There was an error, please check the log file`)

โœ Arguements & Paramaters

  • Content (STRING) - The content or error shown in the log file.
  • Type (STRING) - The type of log, you can view the types below or input a custom type to use your own.
  • Filename (STRING) - The file where the log was invoke, usually __filename.
  • MTD (STRING) - The message to display in console when the log is invoked.

Types

  • Error - This is when you have an error of course, like my code (RED)
  • Log - The standard log (BLUE)
  • Warn - Input when you have a warning (YELLOW)
  • Debug - Standard debug for your projects (GREY)
  • Ready - Made for djs bots just to use in your ready event (GREEN)
  • Success - Like the ready type but for when something goes right (GREEN)
  • Perms - For when you need to say you have no permission in console (MAGENTA)
  • Nodeexc - This is just a standard Uncaught Exception but formatted (RED)
  • Noderejc - Again a standard Unhandled Rejection but formatted (RED)
  • Input a type other than these and it will still show, this is where the custom type comes in (Custom logs will always be blue)

๐Ÿ“ฆ Dependencies

๐Ÿ“‚ Examples

You can find all the examples in the file called examples.js

๐Ÿง‘ Contact

Made with โ™ฅ by IceyyM8


disjs-logger's People

Contributors

icedoesjs avatar

Watchers

 avatar

Forkers

ana817

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.