koa-views
Template rendering middleware for koa.
Installation
$ npm install koa-views
Example
// Must be used before any router is usedapp; app;
For more examples take a look at the tests
API
views([path, opts])
path (__dirname)
: __dirname + where your views are locatedopts
: these options go straight to co-views.
Debug
Set the DEBUG
environment variable to koa-views
when starting your server.
$ DEBUG=koa-views