File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed
Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change 11'use strict' ;
22
33import { createHighlighterCoreSync } from '@shikijs/core' ;
4- import { createJavaScriptRegexEngine } from '@shikijs/engine-javascript ' ;
4+ import { createOnigurumaEngine } from '@shikijs/engine-oniguruma ' ;
55import { toString } from 'hast-util-to-string' ;
66import { h as createElement } from 'hastscript' ;
77import { SKIP , visit } from 'unist-util-visit' ;
@@ -15,7 +15,7 @@ const languagePrefix = 'language-';
1515// Creates a Singleton instance for Shiki's syntax highlighter using WASM
1616const shikiHighlighter = createHighlighterCoreSync ( {
1717 ...shikiConfig ,
18- engine : createJavaScriptRegexEngine ( ) ,
18+ engine : await createOnigurumaEngine ( import ( 'shiki/wasm' ) ) ,
1919} ) ;
2020
2121// Creates a static button element which is used for the "copy" button
You can’t perform that action at this time.
0 commit comments