Fix hexo-generator-type bug.
npm install --save hexo-generator-type2
types:
- blog
- theme
hen hexo load this plugin, it will auto register generator for hexo.config.types
like this code below
hexo.extend.generator.register('blog', build('blog'));
hexo.extend.generator.register('theme', build('theme'));
more detail please read sourcecode, it's simple
create blog.swig
file in layout
dir
write anything you like in the template file
create page blog/test.md
in source
dir
the content as follow
---
title: test blog page
layout: blog
---
this is a blog test page
run hexo generate
and this plugin will create pagination for you auto.