summary refs log tree commit diff stats
path: root/src/index.js
diff options
context:
space:
mode:
authorAlan Pearce2017-06-18 18:23:28 +0200
committerAlan Pearce2017-06-18 18:23:28 +0200
commite13c5726846a89df4196f6abc9fc98d99d48305b (patch)
tree700b4942398c36113425793242a820ce4a8a6b52 /src/index.js
parent33171a749162685e42650f82041cd2af0136718d (diff)
downloadhomestead-e13c5726846a89df4196f6abc9fc98d99d48305b.tar.lz
homestead-e13c5726846a89df4196f6abc9fc98d99d48305b.tar.zst
homestead-e13c5726846a89df4196f6abc9fc98d99d48305b.zip
Rename templates to njk
It's specified in the nunjucks documentation.  Using it allows editors
to understand the syntax better
Diffstat (limited to 'src/index.js')
-rw-r--r--src/index.js6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/index.js b/src/index.js
index fce4c09..242b298 100644
--- a/src/index.js
+++ b/src/index.js
@@ -13,7 +13,11 @@ const view = require('koa-nunjucks-next')
 const Posts = require('./modules/posts.js')
 const posts = Posts.getFolder(process.env.POST_DIR)
 
-app.use(view(`${__dirname}/views`))
+app.use(
+  view(`${__dirname}/views`, {
+    extname: 'njk'
+  })
+)
 
 const postsArray = Array.from(posts.entries())
 router.get('/', async function (ctx) {