@nexssp/dddebug

1.0.7 • Public • Published

@nexssp/dddebug

  • EASY Debugging with USEFUL information

Just simply debug function. no console.log/process.exit -> just ddd with nice debug output and time executed.

  • It shows where stopped with: debugged value (object, array, ...), mulitple values,
  • line number
  • filename
  • filepath
  • exec time
  • current working dir (cwd)

image

Installation

npm i @nexssp/dddebug

Usage

Global

require('@nexssp/dddebug/global') // and from now you can use it everywere..

ddc('debug A')
ddd('stop here', { myvar: debug })

Standard

const { ddd, ddc } = require('@nexssp/dddebug')

ddc({ x: 1 }, ['another', 'var'], 'something else') // will not stop here. ddd will stop

Above will display but program will continue:

dddebug function - continue example display

ddd(varToDebug, anothervar, myobject, myArray);

// OR

const d = require("@nexssp/dddebug").ddd;

const myObject = {'test', {"x":["y"]}};

d(myObject);

Note

Time is calculated from require("@nexssp/dddebug"); so put this at the top of the program. after ddd program will stop, and ddc will continue.

/@nexssp/dddebug/

    Package Sidebar

    Install

    npm i @nexssp/dddebug

    Homepage

    nexss.com

    Weekly Downloads

    5

    Version

    1.0.7

    License

    MIT

    Unpacked Size

    5.98 kB

    Total Files

    4

    Last publish

    Collaborators

    • nexss