'use strict'; (function(window, document, framework) { // Loop through each element in the DOM and collect up all // the templates it has. A template either has data to supply // to others, or it needs data from another template function initTemplates() { var x, el, tmp, emptyTemplates = [], container, templateElements; // collect up all the templates currently in the DOM templateElements = document.body.querySelectorAll("[data-template]"); for(x=0; x