hexojs / Hexo Renderer Markdown It
Licence: mit
Markdown-it is a Markdown parser, done right. A faster and CommonMark compliant alternative for Hexo.
Stars: ✭ 223
Programming Languages
javascript
184084 projects - #8 most used programming language
Labels
Projects that are alternatives of or similar to Hexo Renderer Markdown It
Hexo Prism Plugin
Hexo plugin for code highlighting by prism.js, supporting JSX syntax
Stars: ✭ 195 (-12.56%)
Mutual labels: hexo
Hexo Abbrlink
create one and only link for every post for hexo
Stars: ✭ 212 (-4.93%)
Mutual labels: hexo
Post Scheduler
Schedule posts & content updates for static websites (Jekyll, Hugo, Gatsby, Phenomic etc)
Stars: ✭ 184 (-17.49%)
Mutual labels: hexo
Hexo Theme Miho
🍺一款单栏响应式的hexo主题, A single column response for hexo . https://blog.minhow.com
Stars: ✭ 194 (-13%)
Mutual labels: hexo
Hexo Theme Jsimple
Simple three columns theme for Hexo.Inspired by JianShu.com
Stars: ✭ 210 (-5.83%)
Mutual labels: hexo
Hexo Theme Random
A hexo theme with random fullscreen background image.
Stars: ✭ 179 (-19.73%)
Mutual labels: hexo
Twikoo
一个简洁、安全、免费的静态网站评论系统 | A simple, safe, free comment system.
Stars: ✭ 195 (-12.56%)
Mutual labels: hexo
Hexo All Minifier
A plugin for Hexo that optimizes HTML, CSS, JS and imagages, and it can optionally deploys your blog.
Stars: ✭ 224 (+0.45%)
Mutual labels: hexo
Hexo Theme Hiero
An awesome magazine, blog theme for your Hexo site.
Stars: ✭ 209 (-6.28%)
Mutual labels: hexo
hexo-renderer-markdown-it
This renderer plugin uses Markdown-it as a render engine on Hexo. Adds support for Markdown and CommonMark.
Main Features
- Support for Markdown, GFM and CommonMark
- Extensive configuration
- Faster than the default renderer |
hexo-renderer-marked
- Safe ID for headings
- Anchors for headings with ID
- Footnotes
-
<sub>
H2O -
<sup>
x2 -
<ins>
Inserted
Installation
Follow the installation guide.
Options
markdown:
preset: 'default'
render:
html: true
xhtmlOut: false
langPrefix: 'language-'
breaks: true
linkify: true
typographer: true
quotes: '“”‘’'
enable_rules:
disable_rules:
plugins:
anchors:
level: 2
collisionSuffix: ''
permalink: false
permalinkClass: 'header-anchor'
permalinkSide: 'left'
permalinkSymbol: '¶'
case: 0
separator: '-'
Refer to the wiki for more details.
Extensibility
This plugin overrides some default behaviors of how markdown-it plugin renders the markdown into html, to integrate with the Hexo ecosystem. It is possible to override this plugin too, without resorting to forking the whole thing.
For example, to enable unsafe links (which is disabled by default):
hexo.extend.filter.register('markdown-it:renderer', function(md) {
const { config } = this; // Optional, parse user config from _config.yml
md.validateLink = function() { return true; };
});
// Specify custom function in plugin option
const { slugize } = require('hexo-util');
const opts = hexo.config.markdown.anchors;
const mdSlugize = (str) => {
return slugize(str, { transform: opts.case, ...opts });
};
hexo.extend.filter.register('markdown-it:renderer', function(md) {
md.use(require('markdown-it-table-of-contents'), {
includeLevel: [2,3,4],
slugify: mdSlugize
});
});
Save the file in "scripts/" folder and run Hexo as usual.
Refer to markdown-it API documentation.
Requests and bug reports
If you have any feature requests or bugs to report, you're welcome to file an issue.
Note that the project description data, including the texts, logos, images, and/or trademarks,
for each open source project belongs to its rightful owner.
If you wish to add or remove any projects, please contact us at [email protected].