Created
April 23, 2014 03:30
-
-
Save JanMiksovsky/11201962 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> | |
<head> | |
<meta charset="utf-8"> | |
<title>Dynamic HTML import of element definition doesn't trigger upgrade</title> | |
<script src="http://www.polymer-project.org/platform.js"></script> | |
<!-- If uncommented, the static version of this link works. --> | |
<!-- <link rel="import" href="http://jsbin.com/vovun/2"> --> | |
<script> | |
window.addEventListener( "load", function() { | |
// Dynamically import an element definition. | |
var link = document.createElement( "link" ); | |
link.setAttribute( "rel", "import" ); | |
link.setAttribute( "href", "https://gist.githubusercontent.com/JanMiksovsky/11201938/raw/41ea2e8b1dc2566acbab9ea05e54717108b8426a/gistfile1.html" ); | |
document.head.appendChild( link ); | |
}); | |
</script> | |
</head> | |
<body> | |
<test-element>world</test-element> | |
</body> | |
</html> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment