Skip to content

Commit

Permalink
Netlify: Add MathJax to the Content-Security-Policy
Browse files Browse the repository at this point in the history
  • Loading branch information
fwcd committed Aug 18, 2024
1 parent 3700059 commit 86d7fdc
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion netlify.toml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,8 @@
# also specified inline, and unsafe inline JS script blocks are allowed
# because it's needed for RTD theme navigation and the search function:
# https://github.com/readthedocs/sphinx_rtd_theme/issues/817
Content-Security-Policy = "default-src 'self'; style-src 'self' 'unsafe-inline'; script-src 'self' 'unsafe-inline'"
# We also allow loading MathJax, which is needed to render math formulas.
Content-Security-Policy = "default-src 'self'; style-src 'self' 'unsafe-inline'; script-src 'self' https://cdn.jsdelivr.net/npm/mathjax@3/ 'unsafe-inline'; font-src 'self' https://cdn.jsdelivr.net/npm/mathjax@3/"

# Disable all browser features that we don't need. Unfortunately
# there is no way to specify a default for all directives yet, so
Expand Down

0 comments on commit 86d7fdc

Please sign in to comment.