Package Exports
- subtext
This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (subtext) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
#subtext
HTTP payload parser.
Lead Maintainer - John Brett
subtext parses the request body and exposes it in a callback.
Example
var Http = require('http');
var Subtext = require('subtext');
Http.createServer(function (request, response) {
Subtext.parse(request, null, { parse: true, output: 'data' }, function (err, parsed) {
response.writeHead(200, { 'Content-Type': 'text/plain' });
response.end('Payload contains: ' + parsed.payload.toString());
});
}).listen(1337, '127.0.0.1');
console.log('Server running at http://127.0.0.1:1337/');
API
See the API Reference
