Skip to content

Commit

Permalink
Merge pull request #35 from cntrump/master
Browse files Browse the repository at this point in the history
add variable enableMathJax and fix a build error.
  • Loading branch information
qqpann authored Nov 30, 2019
2 parents 216c469 + 2e1e35a commit 67c96c7
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 2 deletions.
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,8 @@ twitter = "your_twitter_id"
# You can use favicon by addin them manually.
useIcon = true
useTwitterCard = true
# Use MathJax.js. Disabling site-wide and you still can enable in indivisual pages
math = true

shareTo = ["Twitter", "Hatena", "Facebook", "Pocket"]
showFooterCredits = true
Expand Down
3 changes: 2 additions & 1 deletion layouts/_default/baseof.html
Original file line number Diff line number Diff line change
Expand Up @@ -72,10 +72,11 @@
</div>
</div>


{{ if or .Params.math ( default true .Site.Params.math ) }}
<!-- Scripts -->
<script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.5/MathJax.js?config=TeX-AMS-MML_HTMLorMML"></script>
<!-- MathJax -->
<script type="text/x-mathjax-config">MathJax.Hub.Config({ tex2jax: { inlineMath: [['$','$'], ['\\(','\\)']] } });</script>
{{ end }}
</body>
</html>
2 changes: 1 addition & 1 deletion layouts/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ <h3>{{ .Title }}</h3>
{{ end }}

{{ range .Paginator.Pagers }}
<a href="{{ .RelPermalink }}">
<a href="{{ .URL }}">
{{ .PageNumber }}
</a>
{{ end }}
Expand Down

0 comments on commit 67c96c7

Please sign in to comment.