Skip to content

Instantly share code, notes, and snippets.

@robertklep
Last active December 17, 2015 16:19
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save robertklep/5637677 to your computer and use it in GitHub Desktop.
Save robertklep/5637677 to your computer and use it in GitHub Desktop.
var express = require('express');
var app = express();
app.use(function(req, res, next) {
req.on('data', function() {
console.log('read chunk');
});
req.on('end', function() {
console.log('req end');
next();
});
});
app.use(express.bodyParser());
app.all('/', function(req, res) {
res.send('OK');
});
app.listen(3012);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment