Created
November 22, 2017 23:12
-
-
Save vogloblinsky/55c0e73623b475edb4b1f5791c48b2c7 to your computer and use it in GitHub Desktop.
This file contains 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"> | |
<head> | |
<meta charset="utf-8"> | |
<title>Angular Elements Demo</title> | |
</head> | |
<body> | |
<hello-world name="Anna"></hello-world> | |
<script src="dist/main.bundle.js"></script> | |
<script> | |
const helloCp = document.querySelector('hello-world'); | |
helloCp.addEventListener('hi', (data) => { | |
console.log(data.detail); | |
}); | |
setTimeout(() => { | |
helloCp.setAttribute('name', 'Marc'); | |
}, 1000); | |
</script> | |
</body> | |
</html> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment