Skip to content

Instantly share code, notes, and snippets.

@csuwildcat
Created April 11, 2013 03:18
Show Gist options
  • Select an option

  • Save csuwildcat/5360471 to your computer and use it in GitHub Desktop.

Select an option

Save csuwildcat/5360471 to your computer and use it in GitHub Desktop.
/*** Method 1 ***/
<element tagname="x-foo">
<template id="foo-template-1">
<shadowroot>
<div>Baaar me matey!</div>
</shadowroot>
<script scoped>
this.addEventListener('bind', function(e){
// do some sweet bind stuff
});
</script>
</template>
</element>
/*** Method 2 ***/
<template id="foo-template-2">
<shadowroot>
<div>Baaar me matey!</div>
</shadowroot>
<script scoped>
this.addEventListener('bind', function(e){
// do some sweet bind stuff
});
</script>
</template>
<element tagname="x-foo" template="foo-template-2">
<style scoped>
/* Super slick styles for x-foo */
</style>
</element>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment