diff --git a/package.json b/package.json index 97eccc1..d302015 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "vuepress-plugin-demo-code", - "version": "0.4.1", + "version": "0.4.2", "description": "📝 Demo and code plugin for vuepress", "main": "src/index.js", "files": [ diff --git a/src/highlight.js b/src/highlight.js index 9b77bfb..4f2032a 100644 --- a/src/highlight.js +++ b/src/highlight.js @@ -1,9 +1,10 @@ -// https://github.com/vuejs/vuepress/blob/master/packages/@vuepress/markdown/lib/highlight.js - const prism = require('prismjs') const escapeHtml = require('escape-html') const loadLanguages = require('prismjs/components/index') +// prevent Prism calling `highlightAll` +prism.manual = true + // loadLanguages(['markup', 'css', 'javascript']) function wrap (code, lang) {