Skip to content
This repository has been archived by the owner on Sep 20, 2021. It is now read-only.

Commit

Permalink
Configured for Nunjucks
Browse files Browse the repository at this point in the history
  • Loading branch information
Jeff Maher committed Nov 23, 2019
1 parent 8ce6242 commit d516c2d
Show file tree
Hide file tree
Showing 11 changed files with 1,931 additions and 398 deletions.
26 changes: 5 additions & 21 deletions config/views.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,26 +16,10 @@

module.exports.views = {

/***************************************************************************
* *
* Extension to use for your views. When calling `res.view()` in an action, *
* you can leave this extension off. For example, calling *
* `res.view('homepage')` will (using default settings) look for a *
* `views/homepage.ejs` file. *
* *
***************************************************************************/

// extension: 'ejs',

/***************************************************************************
* *
* The path (relative to the views directory, and without extension) to *
* the default layout file to use, or `false` to disable layouts entirely. *
* *
* Note that layouts only work with the built-in EJS view engine! *
* *
***************************************************************************/

layout: 'layouts/layout'
extension: 'njk',
getRenderFn: ()=>{
var cons = require('consolidate')
return cons.nunjucks
}

};
Loading

0 comments on commit d516c2d

Please sign in to comment.