Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

MathJax info shown in references #683

Closed
topepo opened this issue Mar 2, 2019 · 5 comments · Fixed by rstudio/rmarkdown#1594
Closed

MathJax info shown in references #683

topepo opened this issue Mar 2, 2019 · 5 comments · Fixed by rstudio/rmarkdown#1594
Labels
Milestone

Comments

@topepo
Copy link

@topepo topepo commented Mar 2, 2019

The FES references contain a dump of MathJax

The References.Rmd file is

`r if (knitr:::is_html_output()) '
# References {-}
'`
@yihui

This comment has been minimized.

Copy link
Member

@yihui yihui commented May 8, 2019

I cannot tell what happened without the source or a minimal reproducible example...

@topepo

This comment has been minimized.

Copy link
Author

@topepo topepo commented Jun 10, 2019

Finally got around to making one: https://github.com/topepo/MathJax-test.

@yihui yihui added the help wanted label Jun 21, 2019
@yihui

This comment has been minimized.

Copy link
Member

@yihui yihui commented Jun 21, 2019

Thanks for the example! I'm able to reproduce the issue, although I don't have an idea why this occurs at the moment.

@RLesur

This comment has been minimized.

Copy link
Collaborator

@RLesur RLesur commented Jun 30, 2019

I think the problem comes from rmarkdown.
I found a little bug in rmarkdown when a HTML document is rendered with a custom template and mathjax: <some_url>.
For now, here is a workaround for this bug. In https://github.com/topepo/MathJax-test/blob/master/_output.yml, you can use these arguments:

bookdown::gitbook:
  css: FES.css
  dev: svglite
  split_by: section
  mathjax: null
  pandoc_args: --mathjax=https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.5/latest.js?config=TeX-MML-AM_HTMLorMML.js

I will open a PR in rmarkdown to fix this bug.

@yihui

This comment has been minimized.

Copy link
Member

@yihui yihui commented Jul 2, 2019

Thanks to @RLesur, this should be fixed with the development version of rmarkdown:

remotes::install_github('rstudio/rmarkdown')
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
3 participants
You can’t perform that action at this time.