@vercaemer/koa-ssr-router
v0.1.0
Published
File system based router for koa, with templating and api support. By default supports handlebars and CommonJS handlers.
Downloads
1
Readme
koa fs router
features
- request routing based on file system structure
- templating with your favourite engine
- server side props with custom handler
- api endpoints
- parameterized routes
usage
Create your routes folder and mount the middleware.
Use [name]
syntax in folders or files to specify
parameters. Use {{params.name}}
to use them in
your templates.
You can use {{state}}
to access the koa state
object.