From 793aef0e2e949ca542f7570a82823af20cb34ace Mon Sep 17 00:00:00 2001 From: Wu Cheng-Han Date: Mon, 7 Nov 2016 21:27:58 +0800 Subject: [PATCH] Fix syntax highlighting not apply correctly in slides --- public/js/extra.js | 1 - public/js/index.js | 2 ++ public/js/pretty.js | 2 ++ public/views/slide.ejs | 6 +++--- 4 files changed, 7 insertions(+), 4 deletions(-) diff --git a/public/js/extra.js b/public/js/extra.js index 81dd4a2..05d0078 100644 --- a/public/js/extra.js +++ b/public/js/extra.js @@ -1,5 +1,4 @@ require('prismjs/themes/prism.css'); -require('highlight.js/styles/github-gist.css'); var Prism = require('prismjs'); require('prismjs/components/prism-wiki'); diff --git a/public/js/index.js b/public/js/index.js index 9c77ba8..35f6383 100644 --- a/public/js/index.js +++ b/public/js/index.js @@ -6,6 +6,8 @@ require('../css/extra.css'); require('../css/slide-preview.css'); require('../css/site.css'); +require('highlight.js/styles/github-gist.css'); + var toMarkdown = require('to-markdown'); var saveAs = require('file-saver').saveAs; diff --git a/public/js/pretty.js b/public/js/pretty.js index f7d3190..b5c5ba8 100644 --- a/public/js/pretty.js +++ b/public/js/pretty.js @@ -2,6 +2,8 @@ require('../css/extra.css'); require('../css/slide-preview.css'); require('../css/site.css'); +require('highlight.js/styles/github-gist.css'); + /* other vendors plugin */ var S = require('string'); diff --git a/public/views/slide.ejs b/public/views/slide.ejs index 2cc79be..0570b5f 100644 --- a/public/views/slide.ejs +++ b/public/views/slide.ejs @@ -30,6 +30,9 @@ + + + @@ -37,9 +40,6 @@ <%- include build/slide-header %> - - -