-
-
Notifications
You must be signed in to change notification settings - Fork 3.6k
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
Add beta version of doc diff library for testing #9546
Conversation
Yeah, CORS error, about what I expected.
Page that should have a diff: https://docs--9546.org.readthedocs.build/en/9546/versions.html |
That is odd, the HTML is identical 🤔 |
I opened readthedocs/addons#93 to discuss CORS and authentication mitigation at a broad level. |
This is wonderful! Excited to figure out the CORS issue, and have some of this magic in our PR's 🎉 |
@stsewd how hard would be to enable CORS for this particular case? I'd love to see this PR merged and in action for our repository at least. |
@humitos there is an issue related to this at https://github.com/readthedocs/readthedocs-corporate/issues/1482. We should be safe to allow cross site requests on .org, since everything is public, and we don't use cookies on the docs domains (we could even restrict this for domains that are valid on .org only). |
We could use a CORS proxy for this. I already have one running in workers for WTD we could test against: https://cors.writethedocs.workers.dev/corsproxy/?apiurl=https://docs.readthedocs.io/en/stable/ |
Fancy :) |
It works! 💪🏼 Example: https://docs--9546.org.readthedocs.build/en/9546/build-customization.html |
Note, what we added was a hack. I'd wait to merge this until we have a proxy maintained on the RTD side. |
I know that we have worked around on some CORS issues already. Are we ready to merge this PR and start using internally the doc-diff javascript library? |
I'm 👍 on it! Dogfooding ftw. |
e4895ec
to
3174911
Compare
3174911
to
31e7aed
Compare
Nice. |
Very slim chance this works as expected
📚 Documentation previews 📚
docs
): https://docs--9546.org.readthedocs.build/en/9546/dev
): https://dev--9546.org.readthedocs.build/en/9546/