add --mathjax [CONFIG] to inject root-repo/[CONFIG] file,

which is similar to the behavior of --css and --js.
CONFIG is "mathjax.config.js" by default.
This commit is contained in:
Hardy
2014-08-14 18:00:34 -04:00
parent e65a78a5f5
commit ee55b74898
5 changed files with 19 additions and 3 deletions
+9 -3
View File
@@ -31,15 +31,21 @@
<script type="text/javascript" src="{{base_url}}/javascript/identicon_canvas.js"></script>
{{/use_identicon}}
{{#mathjax}}
<script type="text/x-mathjax-config">
MathJax.Hub.Config({
{{^mathjax_config}}
<script type="text/javascript">
window.MathJax = {
tex2jax: {
inlineMath: [ ['\\(','\\)'] ],
displayMath: [ ['$$','$$'], ['\\[','\\]'] ],
processEscapes: true
},
TeX: { extensions: ["autoload-all.js"] }});
TeX: { extensions: ["autoload-all.js"] }
};
</script>
{{/mathjax_config}}
{{#mathjax_config}}
<script type="text/javascript" src="{{base_url}}/{{mathjax_config}}"></script>
{{/mathjax_config}}
<script>(function(d,j){
j = d.createElement('script');
j.src = '//cdn.mathjax.org/mathjax/latest/MathJax.js?config=TeX-AMS-MML_HTMLorMML';