Skip to content

WillKirkmanM/dl

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

18 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Image

A Configurable, Useful Way to Write Debug Log Statements

Get Started

// index.js
#!/usr/bin/env node 
import { DebugLogger } from "@WillKM/DL";

const debug = new DebugLogger({
    enabled: true,
    logLevel: 1,
    prefixMessage: '[DebugLogger] -'
});
     
debug.log(1, "Hello World");

Result

$ node index.js
> [DebugLogger] - Hello World

Why?

I made this as I wanted to regulate what logs showed when providing different verbosity levels.