deadblue / hexo-heading-numbering

A hexo plugin to automatically add numbered index for the headings in hexo post.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

hexo-heading-numbering

Automatically add numbered index for the headings in hexo post.

Example

Assume the post is:

# Top heading
## Sub heading
## Another sub heading
# Another top heading

Then it will be rendered as:

1 Top heading
1.1 Sub heading
1.2 Another sub heading
2 Another top heading

Usage

  1. Run following command in your blog directory.
npm install hexo-heading-numbering --save
  1. Add following content in _config.yml (under blog root directory).
heading_numbering:
  enable: true
  separator: "."
  prefix: ""
  suffix: " "
  1. Clean and rebuild.
hexo cl && hexo g

Support

Hexo v5.x (Tested on v5.4.0)

License

MIT

About

A hexo plugin to automatically add numbered index for the headings in hexo post.

License:MIT License


Languages

Language:JavaScript 100.0%