Bones/node_modules/server-destroy/README.md
SOUTHERNCO\x2mjbyrn 7efe7605b8 Template Upload
2017-05-17 13:45:25 -04:00

22 lines
369 B
Markdown

# server-destroy
Enable destroying a server, and all currently open connections.
## Usage
```javascript
var enableDestroy = require('server-destroy');
var server = http.createServer(function(req, res) {
// do stuff, blah blah blah
});
server.listen(PORT);
// enhance with a 'destroy' function
enableDestroy(server);
// some time later...
server.destroy();
```