File tree Expand file tree Collapse file tree 3 files changed +3
-6
lines changed Expand file tree Collapse file tree 3 files changed +3
-6
lines changed Original file line number Diff line number Diff line change 1+ import hljs from 'highlight.js' ;
12import CustomElementConstructor from '@/class/HTMLCodeBlockElement' ;
23import { mkHighlightCallback } from '@/utils/highlight' ;
34import '@/utils/add-style' ;
45
5- const hljs = require ( 'highlight.js' ) ;
6-
76CustomElementConstructor . highlight = mkHighlightCallback ( hljs ) ;
87customElements . define ( 'code-block' , CustomElementConstructor ) ;
98
Original file line number Diff line number Diff line change 1+ import hljs from 'highlight.js/lib/common' ;
12import CustomElementConstructor from '@/class/HTMLCodeBlockElement' ;
23import { mkHighlightCallback } from '@/utils/highlight' ;
34import '@/utils/add-style' ;
45
5- const hljs = require ( 'highlight.js/lib/common' ) ;
6-
76CustomElementConstructor . highlight = mkHighlightCallback ( hljs ) ;
87customElements . define ( 'code-block' , CustomElementConstructor ) ;
98
Original file line number Diff line number Diff line change 1+ import hljs from 'highlight.js/lib/core' ;
12import CustomElementConstructor from '@/class/HTMLCodeBlockElement' ;
23import { mkHighlightCallback } from '@/utils/highlight' ;
34import '@/utils/add-style' ;
45
5- const hljs = require ( 'highlight.js/lib/core' ) ;
6-
76CustomElementConstructor . highlight = mkHighlightCallback ( hljs ) ;
87customElements . define ( 'code-block' , CustomElementConstructor ) ;
98
You can’t perform that action at this time.
0 commit comments