解决两种高亮工具重复执行的问题

pull/244/head
Minho 2018-03-28 16:04:17 +08:00
parent 07e424474e
commit 98e93a19d5
1 changed files with 3 additions and 0 deletions

View File

@ -70,6 +70,9 @@ function loadDocument($url, $id, $callback) {
*/
function initHighlighting() {
$('pre,pre.ql-syntax').each(function (i, block) {
if($(this).hasClass('prettyprinted')){
return;
}
hljs.highlightBlock(block);
});
hljs.initLineNumbersOnLoad();