File tree Expand file tree Collapse file tree 5 files changed +6
-7
lines changed Expand file tree Collapse file tree 5 files changed +6
-7
lines changed Original file line number Diff line number Diff line change @@ -28,7 +28,6 @@ let { componentName } = require('./config').dev;
28
28
const componentsInPrototype = [ 'Modal' , 'message' , 'notification' ] ;
29
29
30
30
const MAIN_TEMPLATE = `import 'babel-polyfill';
31
- import 'highlight.js/styles/solarized-light.css';
32
31
import Vue from 'vue';
33
32
import Vuex from 'vuex';
34
33
import VueI18n from 'vue-i18n';
Original file line number Diff line number Diff line change 1
1
const path = require ( 'path' ) ;
2
- const hljs = require ( 'highlight.js ' ) ;
2
+ const Prism = require ( 'prismjs ' ) ;
3
3
const Token = require ( 'markdown-it/lib/token' ) ;
4
4
const cheerio = require ( 'cheerio' ) ;
5
5
const WebpackBar = require ( 'webpackbar' ) ;
@@ -43,12 +43,12 @@ const replaceDelimiters = function(str) {
43
43
*/
44
44
45
45
const renderHighlight = function ( str , lang ) {
46
- if ( ! ( lang && hljs . getLanguage ( lang ) ) ) {
46
+ if ( ! ( lang && Prism . languages [ lang ] ) ) {
47
47
return '' ;
48
48
}
49
49
50
50
try {
51
- return replaceDelimiters ( hljs . highlight ( lang , str , true ) . value ) ;
51
+ return replaceDelimiters ( Prism . highlight ( str , Prism . languages [ lang ] , lang ) ) ;
52
52
} catch ( err ) { }
53
53
} ;
54
54
Original file line number Diff line number Diff line change 139
139
"postcss-loader" : " ^3.0.0" ,
140
140
"prettier" : " ^1.18.2" ,
141
141
"pretty-quick" : " ^2.0.0" ,
142
+ "prismjs" : " ^1.19.0" ,
142
143
"querystring" : " ^0.2.0" ,
143
144
"raw-loader" : " ^4.0.0" ,
144
145
"reqwest" : " ^2.0.5" ,
216
217
" lib/**/style/*" ,
217
218
" *.less"
218
219
]
219
- }
220
+ }
Original file line number Diff line number Diff line change @@ -80,7 +80,7 @@ export default [
80
80
component : ( ) => import ( '../antdv-demo/input/demo/index.vue' ) ,
81
81
} ,
82
82
{
83
- path : 'mentions-cn ' ,
83
+ path : 'mentions' ,
84
84
component : ( ) => import ( '../antdv-demo/mentions/demo/index.vue' ) ,
85
85
} ,
86
86
{
Original file line number Diff line number Diff line change @@ -2,7 +2,6 @@ import 'babel-polyfill';
2
2
import '../components/style.js' ;
3
3
import './index.less' ;
4
4
import 'nprogress/nprogress.css' ;
5
- import 'highlight.js/styles/solarized-light.css' ;
6
5
import Vue from 'vue' ;
7
6
import Vuex from 'vuex' ;
8
7
import VueI18n from 'vue-i18n' ;
You can’t perform that action at this time.
0 commit comments