Closed stephlocke closed 7 years ago
I believe anything like this will need to be altered:
default_mathjax <- function() {
paste("https://cdn.mathjax.org/mathjax/latest/",
mathjax_config(), sep="")
}
Yup, we're aware of this and are working on a solution now.
There are some recommendations that can be made that don't involve modifying existing documents but will likely only cover (barely) 30% of use-cases.
One is to write a "mathjax moved" extension for Safari, Firefox and Chrome (I guess you can include Windows ppl's inferior options as well :-p) which will detect the old host URL and then notify that it's being changed and have it select randomly from a list of other CDN sources. It'd be seriously trivial to write. This would be on individuals but RStudio has enough social comms power to reach alot of folks.
Another is to recommend browser more generic browser plugins that can rewrite the host URL component upon retrieval. That's all on individuals, though and I'd be reticent to recommend any third party plugin that wasn't created by RStudio if I were RStudio.
Another is to provide Apache, Nginx, IIS (et al) rewrite rules that show how to point to a locally hosted version or randomly choose other CDNs. This is all on hosting providers and individuals who run servers.
Yet another is to forge a gofundme/indiegogo/kickstarter/etc fundraising campaign to keep the current CDNs funded. That has the widest potential for reach and would end up making the community far more aware of the value of what they were getting for free prior to this.
I would prefer chucking some cash in to keep it running! Or at least to fund a redirect scheme on their end to keep the URLs as-is
Is it the cause of the bugs I encounter with rmarkdown 1.5
? The Mathjax is not correctly rendered in a ioslides presentation.
It could be but MathJax in ioslides appears to be working fine in my configuration. Could you send a minimal reproducible example of what's failing along with your sessionInfo?
On Fri, Apr 28, 2017 at 5:21 AM, stla notifications@github.com wrote:
Is it the cause of the bugs I encounter with rmarkdown 1.5? The Mathjax is not correctly rendered in a ioslides presentation.
— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/rstudio/rmarkdown/issues/1014#issuecomment-297951178, or mute the thread https://github.com/notifications/unsubscribe-auth/AAGXx5kFlZaQKK5q1GXn8Hs3qQ48gF4Hks5r0a-SgaJpZM4M47li .
Hello @jjallaire
For example:
---
title: "Bug rmarkdown"
author: "STLA"
date: "28 avril 2017"
output: ioslides_presentation
---
## Test
Test ${\cal M}$.
The rendering is correct in the RStudio previewer, but not in the browser (Chrome or Vivaldi)
Hmmm... the rendering became correct after I wrote this comment! It just take a couple of minutes.
.... and this has nothing to do with ioslides
This is what I get with a basic html_document
:
But the "M" becomes correct after 10 seconds.
Okay, so it sounds like a network latency problem. Could you provide a HAR file from Chrome for your session? (here's how you do it: https://datameer.zendesk.com/hc/en-us/articles/204847860-How-to-Collect-the-Network-HAR-File-Logs-from-a-Developer-Tools-Session)
This is what I get in the browser console. Maybe this "CORS policiy" is from my company, I don't know. I will test at home.
I've just seen your latest comment now. I'm going to try..
The har
file is too big, I cannot paste it here.
Below are some parts related to MathJax. Does it help ?
"entries": [
{
"startedDateTime": "2017-04-28T13:27:24.083Z",
"time": 5.083000000013271,
"request": {
"method": "GET",
"url": "https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.1/MathJax.js?config=TeX-AMS-MML_HTMLorMML",
"httpVersion": "unknown",
"headers": [
{
"name": "User-Agent",
"value": "Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/57.0.2987.111 Safari/537.36 Vivaldi/1.8.770.50"
}
],
"queryString": [
{
"name": "config",
"value": "TeX-AMS-MML_HTMLorMML"
}
],
"cookies": [],
"headersSize": -1,
"bodySize": 0
},
"response": {
"status": 200,
"statusText": "",
"httpVersion": "unknown",
"headers": [
{
"name": "date",
"value": "Thu, 27 Apr 2017 08:48:41 GMT"
},
{
"name": "content-encoding",
"value": "gzip"
},
{
"name": "cf-cache-status",
"value": "HIT"
},
{
"name": "last-modified",
"value": "Tue, 25 Apr 2017 14:33:46 GMT"
},
{
"name": "server",
"value": "cloudflare-nginx"
},
{
"name": "status",
"value": "200"
},
{
"name": "vary",
"value": "Accept-Encoding"
},
{
"name": "content-type",
"value": "application/javascript; charset=utf-8"
},
{
"name": "access-control-allow-origin",
"value": "*"
},
{
"name": "cache-control",
"value": "public, max-age=30672000"
},
{
"name": "cf-ray",
"value": "35608634fe3f4481-BRU"
},
{
"name": "expires",
"value": "Tue, 17 Apr 2018 08:48:41 GMT"
}
],
"cookies": [],
"content": {
"size": 63048,
"mimeType": "application/javascript",
I go to home, see you later.
Okay, that is extremely helpful! This is an issue we've seen before with MathJax redirects over https. We will deploy an improved version that surmounts this problem to mathjax.rstudio.com shortly!
Thanks!
It should be fixed now.
Yes, it works now. Thank you!
Hello @jjallaire , @yihui
I still have these errors in the console:
My shiny app includes an html file in an iframe tag, and this file does not appear. Previously that worked perfectly. Did something change recently ? I have not changed anything to my app, that's why I suspect a change from your side, maybe related to these error messages.
@jjallaire , @yihui
Forget my message. This is an issue with Chrome. The app works correctly in Vivaldi.
This old thread has been automatically locked. If you think you have found something related to this, please open a new issue by following the issue guide (https://yihui.org/issue/), and link to this old issue if necessary.
I believe y'all use the mathjax CDN which is now unfortunately closing. The impact needs to be assessed and potentially a new CDN used by the package. https://www.mathjax.org/cdn-shutting-down/