rrestjs
Version:
HIgh performance node.js ROA & RESTFUL web framework.
15 lines (14 loc) • 463 B
JavaScript
module.exports.rrestjsconfig = require('./config/post.conf.js');
var http = require('http'),
rrest = require('../'),
server = http.createServer(function (req, res) {
if(req.method === 'POST'){
if(req.apibody){
res.api(req.apibody);
}
else{
res.sendjson(req.param)
}
}
}).listen(rrest.config.listenPort);
console.log('please request use dev http')