Automatic excerpt generator for Hexo
Switch branches/tags
Nothing to show
Clone or download
Pull request Compare This branch is even with chekun:master.
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
lib
tests
.eslintignore
.eslintrc
.gitignore
.jscsrc
.npmignore
.travis.yml
LICENSE
README.md
index.js
package-lock.json
package.json

README.md

hexo-excerpt

Build Status NPM version Coverage Status

Automatic excerpt generator for Hexo!.

Hexo-excerpt: https://chekun.me/post/hexo-excerpt

Installation

$ npm install hexo-excerpt --save

This Plugin use es6 syntax, make sure your node support it.

Features

  • still works!
  • If you're lazy as I am, the plugin generate the excerpt for you, without breaking your sentences or codes!
  • If no tag is specified, the post will be updated with excerpt and more variables.
  • CSS selector can be used to filter generated excerpt.

How?

This plugin runs through all your posts, if your post has more than the configured number of direct tags, then they will be the excerpt, otherwise the whole post will be used.

Configuration

You can specify the size of the excerpt by setting depth in your config, which defaults to 10. You can also exclude certain tags from the generated excerpt using css selectors. Tags matching any of the selectors will be excluded.

excerpt:
  depth: 10
  excerpt_excludes: []
  more_excludes: []

License

MIT