Skip to content
Browse files

Expose page when rendering Paginated pages

Useful if your templates have things like menu blocks and
expect locals similar to the markdown pages
  • Loading branch information...
uvcrew committed Jun 21, 2019
1 parent 196f478 commit 17176c6ac7e59ea84325f85da2b60e59c37c7f04
Showing with 1 addition and 1 deletion.
  1. +1 −1 examples/blog/plugins/
@@ -46,7 +46,7 @@ module.exports = (env, callback) ->
return callback new Error "unknown paginator template '#{ options.template }'"

# setup the template context
ctx = {@articles, @pageNum, @prevPage, @nextPage}
ctx = {@articles, @pageNum, @prevPage, @nextPage, page: this}

# extend the template context with the enviroment locals
env.utils.extend ctx, locals

0 comments on commit 17176c6

Please sign in to comment.
You can’t perform that action at this time.