|
@ -18,17 +18,28 @@ import md_sup from 'markdown-it-sup' |
|
|
let mdHtml, mdSrc, permalink, scrollMap |
|
|
let mdHtml, mdSrc, permalink, scrollMap |
|
|
|
|
|
|
|
|
const defaults = { |
|
|
const defaults = { |
|
|
html: false, // Enable HTML tags in source
|
|
|
// Enable HTML tags in source
|
|
|
xhtmlOut: false, // Use '/' to close single tags (<br />)
|
|
|
html: false, |
|
|
breaks: false, // Convert '\n' in paragraphs into <br>
|
|
|
|
|
|
langPrefix: 'language-', // CSS language prefix for fenced blocks
|
|
|
// Use '/' to close single tags (<br />)
|
|
|
linkify: true, // autoconvert URL-like texts to links
|
|
|
xhtmlOut: false, |
|
|
typographer: true, // Enable smartypants and other sweet transforms
|
|
|
|
|
|
|
|
|
// Convert '\n' in paragraphs into <br>
|
|
|
|
|
|
breaks: false, |
|
|
|
|
|
|
|
|
|
|
|
// CSS language prefix for fenced blocks
|
|
|
|
|
|
langPrefix: 'language-', |
|
|
|
|
|
|
|
|
|
|
|
// autoconvert URL-like texts to links
|
|
|
|
|
|
linkify: true, |
|
|
|
|
|
|
|
|
|
|
|
// Enable smartypants and other sweet transforms
|
|
|
|
|
|
typographer: true, |
|
|
|
|
|
|
|
|
// options below are for demo only
|
|
|
// options below are for demo only
|
|
|
_highlight: true, |
|
|
_highlight: true, |
|
|
_strict: false, |
|
|
_strict: false, |
|
|
_view: 'html' // html / src / debug
|
|
|
_view: 'html' // html / src / debug
|
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
defaults.highlight = function (str, lang) { |
|
|
defaults.highlight = function (str, lang) { |
|
|