0.0.5 • Published 5 years ago

route-now v0.0.5

Weekly downloads
5
License
ISC
Repository
github
Last release
5 years ago

Express inspired ultra fast and minimalist router for serverless functions. Uses trouter and qs

Note: The api is still in flux. I would not use this library yet.

	const Router = require('route-now')
	const app = Router()
	app.use(authenticate)
	app.get('/', handle)
	app.post('/', handle)
	app.put('/', handle)
	app.delete('/', handle)

	module.exports = app.handler

	function authenticate(req, res) {
		if (!auth) throw({statusCode: 401})
	}

	function handle(req, res) {
		res.json({foo: 'bar'})
	}
0.0.5

5 years ago

0.0.4

5 years ago

0.0.3

5 years ago

0.0.2

5 years ago

0.0.1

5 years ago