node package manager

Introducing npm Enterprise add-ons. Integrate third-party dev tools into npm…

obedient

Minimal http framework with the nothing but middleware.

Install: npm install obedient


app.get(route, callback)

Connect style routing for GET http methods. Missing routes will throw a 404.

app.post(route, callback)

Connect style routing for POST http methods. Missing routes will throw a 404.

app.put(route, callback)

Connect style routing for PUT http methods. Missing routes will throw a 404.

app.delete(route, callback)

Connect style routing for DELETE http methods. Missing routes will throw a 404.

app.listen(port)

Port for server to listen on.

app.use(route, middleware)

Connect style middleware. route is an optional field. If set, the middleware will be mounted at that particular route and the prefix will be ignored. So /public/example.js would be treated as /example.js and the middleware would only be run if URL started with /public.

Router documentation: https://github.com/aaronblohowiak/routes.js


View the examples


npm test