Skip to content

Commit

Permalink
Allow user to change mathjax urls in render_math
Browse files Browse the repository at this point in the history
Set 'source' as editable value in render_math settings,
allowing user to change mathjax script urls to their
preferred CDN, in case of bad network condition.
  • Loading branch information
chaserhkj committed Mar 19, 2016
1 parent d3c805d commit 11ea7a5
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion render_math/math.py
Original file line number Diff line number Diff line change
Expand Up @@ -107,6 +107,9 @@ def process_settings(pelicanobj):
if key == 'indent':
mathjax_settings[key] = value

if key == 'source':
mathjax_settings[key] = value

if key == 'show_menu' and isinstance(value, bool):
mathjax_settings[key] = 'true' if value else 'false'

Expand Down Expand Up @@ -155,7 +158,7 @@ def process_settings(pelicanobj):
mathjax_settings[key] = 'true' if value else 'false'

if key == 'force_tls' and isinstance(value, bool):
mathjax_settings[key] = 'true' if value else 'false'
mathjax_settings[key] = 'true' if value else 'false'

if key == 'responsive_break' and isinstance(value, int):
mathjax_settings[key] = str(value)
Expand Down

0 comments on commit 11ea7a5

Please sign in to comment.