Skip to content

Instantly share code, notes, and snippets.

@viller239
Last active September 6, 2017 12:25
Show Gist options
  • Select an option

  • Save viller239/3bad564bf748090a41832f92bfa7b8a8 to your computer and use it in GitHub Desktop.

Select an option

Save viller239/3bad564bf748090a41832f92bfa7b8a8 to your computer and use it in GitHub Desktop.
<!DOCTYPE html>
<html>
<head>
</head>
<body>
<script>
var e = document.createElement('link');
e.rel = 'import';
e.href = 'https://rawgit.com/viller239/242ad1bc1e96cf74304adc86057284e3/raw/7653148bfeec5d0d1910ef343c1ba676199542b6/file2.html';
e.addEventListener('load', x => console.log(x));
e.addEventListener('error', x => console.log(x));
document.head.appendChild(e);
</script>
<div id=a>a</div>
<div id=b>b</div>
</body>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment