Permalink
Browse files

Add ability to specify custom highlight.js url.

  • Loading branch information...
jbub committed Aug 3, 2017
1 parent f570511 commit c2b1d0d41f4e7fe744c2caca68b3ef935ed09e22
Showing with 14 additions and 1 deletion.
  1. +2 −0 README.md
  2. +2 −0 exampleSite/config.toml
  3. +9 −1 layouts/partials/footer.html
  4. +1 −0 layouts/partials/header.html
View
@@ -70,6 +70,8 @@ disqusShortname = "XXX"
shareGooglePlus = true
shareLinkedIn = false
dateFormat = "Mon, Jan 2, 2006"
highlightJsUrl = ""
highlightJsLocalUrl = ""
[Permalinks]
post = "/:year/:month/:day/:filename/"
View
@@ -30,6 +30,8 @@ googleAnalytics = "XXX"
shareGooglePlus = true
shareLinkedIn = false
dateFormat = "Mon, Jan 2, 2006"
highlightJsUrl = ""
highlightJsLocalUrl = ""
[Permalinks]
post = "/:year/:month/:day/:filename/"
@@ -23,8 +23,16 @@ <h1 class="site-title">
</footer>
<script src="{{ .Site.BaseURL }}js/jquery-1.11.3.min.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/9.9.0/highlight.min.js"></script>
<script src="{{ .Site.BaseURL }}js/jquery.fitvids.js"></script>
{{ if .Site.Params.highlightJsUrl }}
<script src="{{ .Site.Params.highlightJsUrl }}"></script>
{{ else if .Site.Params.highlightJsLocalUrl }}
<script src="{{ .Site.BaseURL }}{{ .Site.Params.highlightJsLocalUrl }}"></script>
{{ else }}
<script src="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/9.12.0/highlight.min.js"></script>
{{ end }}
<script src="{{ .Site.BaseURL }}js/scripts.js"></script>
</body>
</html>
@@ -14,6 +14,7 @@
<link rel="stylesheet" href="{{ .Site.BaseURL }}dist/styles.css">
<link rel="stylesheet" href="https://fonts.googleapis.com/css?family=Open+Sans:300italic,400italic,600italic,700italic,400,600,700,300&subset=latin,cyrillic-ext,latin-ext,cyrillic">
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/font-awesome/4.7.0/css/font-awesome.min.css">
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/9.12.0/styles/default.min.css">
{{ if .RSSLink }}
<link href="{{ .RSSLink }}" rel="alternate" type="application/rss+xml">
{{ end }}

0 comments on commit c2b1d0d

Please sign in to comment.