inspect-brk

0.1.2 • Public • Published

inspect-brk 🔎

A small helper to make debugging Node more convenient.

Install

$ yarn add -D inspect-brk

or

$ npm install --save-dev inspect-brk

Usage

Say you have a project like this one and you want to debug $ yarn build:

{
  "name": "cool-example",
  "version": "0.1.0",
  "scripts": {
    "build": "webpack --config webpack.build.js"
  },
  "devDependencies": {
    "webpack": "^3.10.0"
  }
}

You would just write this and run $ yarn debug:build:

{
  "name": "cool-example",
  "version": "0.1.0",
  "scripts": {
    "build": "webpack --config webpack.build.js",
    "debug:build": "inspect-brk build webpack"
  },
  "devDependencies": {
    "inspect-brk": "^0.1.0",
    "webpack": "^3.10.0"
  }
}

This basically turns "webpack --config webpack.build.js" into "node --inspect-brk path/to/node_modules/.bin/webpack --config webpack.build.js". You don't need to worry about the concrete path and the params you use. 💕

You can also have a look into this example.

Dependents (0)

Package Sidebar

Install

npm i inspect-brk

Weekly Downloads

266

Version

0.1.2

License

MIT

Unpacked Size

3.04 kB

Total Files

4

Last publish

Collaborators

  • donaldpipowitch