express-server-with-commands
v1.0.0
Published
Start, stop, restart, and interrogate an Express instance
Downloads
1
Readme
express-server-with-commands
A wrapper for Express to provide start
, stop
, and restart
functionality.
Written out of annoyance and to avoid future copy/paste errors.
Usage
npm install express-server-with-commands
express = require('express-server-with-commands');
// Example setup
asyncOperation(function (results) {
express.start();
});
// Example special cases
exampleListener.on('executiveOverride', function () {
express.stop();
});
exampleListener.on('reset', function () {
express.restart();
});