Rather than putting templates in DOM nodes, output JS functions themselves. This fixes transpiling for IE11, where ES6 parts of the templates wouldn't get passed through Babel.