Created
June 4, 2018 06:05
-
-
Save my-slab/58463779ca8bbb183b0c734fa8d709bc to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!doctype html> | |
<html lang="en"> | |
<body> | |
<iframe id="theIframe" width="400" height="600" sandbox="allow-popups allow-scripts allow-forms allow-same-origin"></iframe> | |
<script> | |
var html = '<html><h1>hello world!</h1></html>' | |
var blob = new Blob([html], {type: 'text/html'}) | |
var url = URL.createObjectURL(blob) | |
theIframe.src = url | |
</script> | |
</body> | |
</html> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment