You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I made a version of this website that uses an iframe at full size to render the HTML content, which removes the needs for tricks like this one, and allows more complex pages to load correctly.
It uses iframeresizer to resize the iframe to match the content size. We fetch the HTML content from the raw URL like is done today, and then generate an object URL from the HTML content to use as the iframe source.
Would you be interested in a PR? It would replace most of the existing codebase, but it seems like a more stable solution, and I suspect that it solves some of the currently open issues.
-fons
The text was updated successfully, but these errors were encountered:
Thanks for the suggestion! As an author of
https://github.com/niutech/x-frame-bypass, I was thinking about this
approach, but there were some problems with framebusters and memory
usage of iframes. I will think about it again with HTML Preview v 2.0.
Hi!
I made a version of this website that uses an iframe at full size to render the HTML content, which removes the needs for tricks like this one, and allows more complex pages to load correctly.
It uses iframeresizer to resize the iframe to match the content size. We fetch the HTML content from the raw URL like is done today, and then generate an object URL from the HTML content to use as the iframe source.
Try it out here:
(Source code is available on the top right of the page)
As an example, this HTML file does not work on the current site, likely because of script loading issues, but it does work with the iframe strategy:
https://github.com/mossr/PlutoNotebooks/blob/master/html/em_algorithm.html
I also added direct support for gist urls like https://gist.github.com/fonsp/a06a1359b612d22f7dbdb6256da1cf2d
Would you be interested in a PR? It would replace most of the existing codebase, but it seems like a more stable solution, and I suspect that it solves some of the currently open issues.
-fons
The text was updated successfully, but these errors were encountered: