Markdown 解析器 Remarkable
- 授权协议: MIT
- 开发语言: JavaScript
- 操作系统: 跨平台
- 软件首页: http://jonschlinkert.github.io/remarkable/demo/
- 软件文档: https://github.com/jonschlinkert/remarkable
软件介绍
Remarkable 是一个纯 JavaScript 的 Markdown 解析器,解析速度快而且易于扩展。100% 支持 Commonmark
使用方法:
var Remarkable = require('remarkable');
// This values are default
var md = new Remarkable({
html: false, // Enable html tags in source
xhtmlOut: false, // Use '/' to close single tags (<br />)
breaks: false, // Convert '\n' in paragraphs into <br>
langPrefix: 'language-', // CSS language prefix for fenced blocks
linkify: false, // Autoconvert url-like texts to links
typographer: false, // Enable smartypants and other sweet transforms
// Highlighter function. Should return escaped html,
// or '' if input not changed
highlight: function (/*str, , lang*/) { return ''; }
});
console.log(md.render('# Remarkable rulezz!'));
// => <h1>Remarkable rulezz!</h1>
