Skip to content

Instantly share code, notes, and snippets.

View ttcremers's full-sized avatar
🤦‍♂️
The neck bone's connected to the head bone

Thomas Cremers ttcremers

🤦‍♂️
The neck bone's connected to the head bone
View GitHub Profile
@ttcremers
ttcremers / polymer-templatize-example.html
Created July 23, 2018 14:13
Simple example of the Polymer.Templatize API in a component (Polymer 2.0).
<link rel="import" href="../polymer/polymer-element.html">
<dom-module id="polymer-templatize-example">
<template>
<style>
:host {
display: block;
}
</style>
// rAF
window.requestAnimationFrame = function() {
return window.requestAnimationFrame ||
window.webkitRequestAnimationFrame ||
window.mozRequestAnimationFrame ||
window.msRequestAnimationFrame ||
window.oRequestAnimationFrame ||
function(f) {
window.setTimeout(f,1e3/60);
}