Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/diogo-karma/kpax
Ultralight and fastest RESTful
https://github.com/diogo-karma/kpax
Last synced: 14 days ago
JSON representation
Ultralight and fastest RESTful
- Host: GitHub
- URL: https://github.com/diogo-karma/kpax
- Owner: diogo-karma
- License: mit
- Created: 2014-04-08T00:19:18.000Z (over 10 years ago)
- Default Branch: master
- Last Pushed: 2016-04-27T16:17:04.000Z (over 8 years ago)
- Last Synced: 2024-10-03T02:24:34.561Z (about 1 month ago)
- Language: JavaScript
- Size: 1.24 MB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
kpax - v0.0.5
====Ultralight and fastest RESTful for NodeJS/Express/AngularJS
### Instalation:
```bash
$ npm install --save kpax
```### Example:
```javascript
var express = require('express');
var app = express();
var server = http.createServer(app);
var kpax = require('kpax')(server);// methods: [get, post, put, head, del]
kpax.get('/something', function(req, res) {
if(req.params.id) {
findById(req.params.id, function(err, ret) {
res.send(ret);
});
} else {
res.send('not found')
}
});// or using kpax-prefix on express
app.post('kpax:/something', function(req, res) {});
```**Copyright (c) 2014 Dg Nechtan**
MIT