$('body').template() should work
- Set the default selector as
script[type="text/html"], .template
. So$('body').template()
will apply templates on all nodes matching the selector -- including the root element, i.e. 'body'. - Setting
data-selector=
on the parent class (e.g. 'body' in the above example) should change the default selector