Skip to content

Commit 48c085a

Browse files
committed
fix(markdown): load some languages by default to partially avoid prism issue
1 parent 081b571 commit 48c085a

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

packages/@vuepress/markdown/src/plugins/codePlugin/resolveHighlighter.ts

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,10 @@ import type { HighlightLanguage } from './languages'
66
// eslint-disable-next-line no-import-assign
77
loadLanguages.silent = true
88

9+
// load some commonly used languages to partially avoid the following issue
10+
// @see https://github.com/PrismJS/prism/issues/2716
11+
loadLanguages(['markdown', 'jsdoc', 'yaml'])
12+
913
export type Highlighter = (code: string) => string
1014

1115
/**

0 commit comments

Comments
 (0)