Skip to content

๐Ÿ“ An automatic logger and debugging program for your JS Projects

Notifications You must be signed in to change notification settings

amanjagdev/auto-log-me

Folders and files

NameName
Last commit message
Last commit date

Latest commit

ย 

History

17 Commits
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 

Repository files navigation

auto-log-me

A Logger to Debug your JS Projects.

Description

It logs the name of the function you called it in along with the message that you send with it

Installation

yarn add auto-log-me

OR

npm install auto-log-me

Usage

Import

const { autoLog, autoLogE, autoLogI, autoLogW } = require('auto-log-me');

OR

import { autoLog, autoLogE, autoLogI, autoLogW } from 'auto-log-me';

Functions

autoLog() --> for basic messages
autoLogI() --> for info messages
autoLogW() --> for warning messages
autoLogE() --> for error messages

Usage

const CalledInThis = () => {
    const foo = "Value of foo";
    const foosome = {
        value: "This is a object"
    };

    autoLogI('Hi');
    autoLogW('Hi');
    autoLog('Hi');
    autoLogE('Hi');
    autoLogI();
    autoLogW();
    autoLog();
    autoLogE();
    autoLogI('', { foo, foosome });
    autoLogW('', { foo, foosome });
    autoLogE('You can even write errors', { foo, foosome });
    autoLog('', { foo, foosome });
}
CalledInThis();

OUTPUT(Color Coded):

Output Photo

Releases

No releases published

Packages

No packages published