npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

grunt-node-inspector

v1.0.0

Published

Run node-inspector with the rest of your workflow to debug node.js

Downloads

7,077

Readme

grunt-node-inspector

Run node-inspector as a grunt task for easy configuration and integration with the rest of your workflow.

NPM version Dependency Status Travis Status

Getting Started

If you haven't used grunt before, be sure to check out the Getting Started guide, as it explains how to create a gruntfile as well as install and use grunt plugins. Once you're familiar with that process, install this plugin with this command:

npm install grunt-node-inspector --save-dev

Then add this line to your project's Gruntfile.js gruntfile:

grunt.loadNpmTasks('grunt-node-inspector');

Documentation

Usage

The minimal usage of node-inspector runs with no options:

'node-inspector': {
  dev: {}
}

When this is run, node-inspector will be available at 0.0.0.0:8080.

Here is a config that uses all of the available options for node-inspector:

'node-inspector': {
  custom: {
    options: {
      'web-host': 'localhost',
      'web-port': 1337,
      'debug-port': 5857,
      'save-live-edit': true,
      'preload': false,
      'hidden': ['node_modules'],
      'stack-trace-limit': 4,
    }
  }
}

To start node-inspector to listen over HTTPS, use the ssl-key and ssl-cert options:

'node-inspector': {
  custom: {
    options: {
      'web-host': 'localhost',
      'web-port': 1337,
      'debug-port': 5857,
      'ssl-key': './ssl/key.pem',
      'ssl-cert': './ssl/cert.pem'
    }
  }
}

Options

web-port

Type: Number Default: 8080

Port to host the inspector.

web-host

Type: String Default: '0.0.0.0'

Host to listen on.

debug-port

Type: Number Default: 5858

Port to connect to the debugging app.

save-live-edit

Type: Boolean Default: false

Save live edit changes to disk.

preload

Type: Boolean Default: true

Enables preloading *.js files. Set to false to speed up startup

stack-trace-limit

Type: Number Default: 50

Number of stack frames to show on a breakpoint.

hidden

Type: Array Default: []

Array of files to hide from the UI (breakpoints in these files will be ignored).

ssl-key

Type: String Default: ''

A file containing a valid SSL key for starting inspector listening over HTTPS.

ssl-cert

Type: String Default: ''

A file containing a valid SSL certificate for starting inspector listening over HTTPS.

Changelog

1.0.0 - Moved to v1 final. Codebase is identical to 0.5.0, so no breaking changes are anticipated.

0.5.0 - Bumped node-inspector version to ^1.1.1.

0.4.2 - Add support for node v5/6. Updated deps.

0.4.1 - Chore release (fix README).

0.4.0 - Changed --no-preload option to --preload. Fixed --hidden option parsing. Added SSL options. Support node v4.

Breaking changes:

options['no-preload'] is now options.preload. If you previously set no-preload to true, you should change your gruntfile to set preload to false.

0.3.0 - Bumped node-inspector version to ^0.12.3.

0.2.0 - Bumped node-inspector version to ^0.10.0.

0.1.6 - Bumped node-inspector version to ^0.9.0 (compatible with latest Chrome updates).

0.1.5 - Added --hidden option for hiding certain files/directories.

0.1.3 - Bumped node-inspector version to ~0.7.0, adding --no-preload option for faster loading.

0.1.2 - Bumped node-inspector version to ~0.6.0, adding the new --stack-trace-limit option. Allowed node-inspector to be listed as a dependency in a project's package.json instead of forcing it to be in grunt-node-inspector's node_modules folder.

0.1.1 - Bumped node-inspector version to ~0.5.0.

0.1.0 - Added debug-port and save-live-edit options. Renamed port to web-port and host to web-host to match node-inspector cli naming.

Breaking changes:

options.host is now options['web-host'] and options.port is now options['web-port'].

0.0.1 - Initial release