Skip to content

Commit

Permalink
Disallow Nunjucks filesystem loader cache to reflect included file ch…
Browse files Browse the repository at this point in the history
…anges
  • Loading branch information
astronomersiva committed Oct 21, 2019
1 parent f303304 commit 9323bea
Showing 1 changed file with 10 additions and 1 deletion.
11 changes: 10 additions & 1 deletion lib/utils/generateHtmlFromNunjucks.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,16 @@ const nunjucks = require('nunjucks');

const { LAYOUTS } = require('./constants');

const nunjucksEnv = new nunjucks.Environment(new nunjucks.FileSystemLoader(LAYOUTS), { autoescape: false });
const nunjucksEnv = new nunjucks.Environment(
new nunjucks.FileSystemLoader(
LAYOUTS, {
autoescape: false,
noCache: true
}
), {
autoescape: false
}
);

nunjucksEnv.addGlobal('Date', new Date());

Expand Down

0 comments on commit 9323bea

Please sign in to comment.