@@ -71,18 +71,30 @@ module.exports = {
7171 filename : path . join ( __dirname , 'public/views/build/cover-pack-scripts.ejs' ) ,
7272 inject : false
7373 } ) ,
74+ new HtmlWebpackPlugin ( {
7475 template : 'public/views/includes/header.ejs' ,
75- chunks : [ 'vendor ' , 'pretty' ] ,
76+ chunks : [ 'font' , 'pretty-styles ', 'pretty' ] ,
7677 filename : path . join ( __dirname , 'public/views/build/pretty-header.ejs' ) ,
7778 inject : false
7879 } ) ,
80+ new HtmlWebpackPlugin ( {
81+ template : 'public/views/includes/header.ejs' ,
82+ chunks : [ 'font-pack' , 'pretty-styles-pack' , 'pretty-styles' , 'pretty' ] ,
83+ filename : path . join ( __dirname , 'public/views/build/pretty-pack-header.ejs' ) ,
84+ inject : false
85+ } ) ,
7986 new HtmlWebpackPlugin ( {
8087 template : 'public/views/includes/scripts.ejs' ,
81- chunks : [ 'vendor' , ' pretty'] ,
88+ chunks : [ 'pretty' ] ,
8289 filename : path . join ( __dirname , 'public/views/build/pretty-scripts.ejs' ) ,
8390 inject : false
8491 } ) ,
8592 new HtmlWebpackPlugin ( {
93+ template : 'public/views/includes/scripts.ejs' ,
94+ chunks : [ 'common' , 'pretty-pack' ] ,
95+ filename : path . join ( __dirname , 'public/views/build/pretty-pack-scripts.ejs' ) ,
96+ inject : false
97+ } ) ,
8698 template : 'public/views/includes/header.ejs' ,
8799 chunks : [ 'vendor' , 'slide' ] ,
88100 filename : path . join ( __dirname , 'public/views/build/slide-header.ejs' ) ,
@@ -121,7 +133,6 @@ module.exports = {
121133 ] ,
122134
123135 entry : {
124- pretty : path . join ( __dirname , 'public/js/pretty.js' ) ,
125136 slide : path . join ( __dirname , 'public/js/slide.js' ) ,
126137 font : path . join ( __dirname , 'public/css/google-font.css' ) ,
127138 "font-pack" : path . join ( __dirname , 'public/css/font.css' ) ,
@@ -222,6 +233,39 @@ module.exports = {
222233 path . join ( __dirname , 'public/js/reveal-markdown.js' ) ,
223234 path . join ( __dirname , 'public/js/index.js' )
224235 ] ,
236+ pretty : [
237+ "expose?filterXSS!xss" ,
238+ "flowchart.js" ,
239+ "js-sequence-diagrams" ,
240+ path . join ( __dirname , 'public/js/reveal-markdown.js' ) ,
241+ path . join ( __dirname , 'public/js/pretty.js' )
242+ ] ,
243+ "pretty-styles" : [
244+ path . join ( __dirname , 'public/css/github-extract.css' ) ,
245+ path . join ( __dirname , 'public/css/mermaid.css' ) ,
246+ path . join ( __dirname , 'public/css/markdown.css' )
247+ ] ,
248+ "pretty-styles-pack" : [
249+ path . join ( __dirname , 'node_modules/bootstrap/dist/css/bootstrap.min.css' ) ,
250+ path . join ( __dirname , 'node_modules/font-awesome/css/font-awesome.min.css' ) ,
251+ path . join ( __dirname , 'node_modules/ionicons/css/ionicons.min.css' ) ,
252+ path . join ( __dirname , 'node_modules/octicons/octicons/octicons.css' )
253+ ] ,
254+ "pretty-pack" : [
255+ "expose?jsyaml!js-yaml" ,
256+ "script!mermaid" ,
257+ "expose?moment!moment" ,
258+ "script!handlebars" ,
259+ "expose?hljs!highlight.js" ,
260+ "expose?emojify!emojify.js" ,
261+ "expose?filterXSS!xss" ,
262+ "script!gist-embed" ,
263+ "flowchart.js" ,
264+ "js-sequence-diagrams" ,
265+ "expose?Viz!viz.js" ,
266+ path . join ( __dirname , 'public/js/reveal-markdown.js' ) ,
267+ path . join ( __dirname , 'public/js/pretty.js' )
268+ ] ,
225269 ]
226270 } ,
227271
0 commit comments