Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

gulp-nodemon

Package Overview
Dependencies
Maintainers
1
Versions
26
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

gulp-nodemon

A gulp task that will reload your node script when it changes.

  • 1.0.0
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
39K
increased by7.48%
Maintainers
1
Weekly downloads
 
Created
Source

gulp-nodemon

A gulp task that will re-load your node script when it changes. Perfect for development.

Usage

nodemon([options])

You can pass an object to gulp-nodemon with options specified in nodemon config.

Example below will start server.js in development mode and watch for changes, as well as watch all .html and .js files in the directory.

{
  script: 'server.js'
, ext: 'js html'
, env: { 'NODE_ENV': 'development' }
}

gulp-nodemon returns a stream just like any other NodeJS stream, except for the on method, which conveniently takes gulp task names to execute.

.on([event], [tasks])
  1. [event] is an event name as a string. (see: nodemon events)
  2. [tasks] A gulp task name, array of gulp task names, or a function to execute.

Example

The following example will run your code with nodemon and lint it when your make changes.

// Gulpfile.js
var gulp = require('gulp')
  , nodemon = require('gulp-nodemon')
  , jshint = require('gulp-jshint')

gulp.task('lint', function () {
  gulp.src('./**/*.js')
    .pipe(jshint())
})

gulp.task('develop', function () {
  nodemon({ script: 'server.js', ext: 'html js', ignore: ['ignored.js'] })
    .on('restart', ['lint'])
})

Keywords

FAQs

Package last updated on 21 Feb 2014

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc