You don't need to put a whole document's <html> in template but you can just insert (append) template that contains <style> tag into document's <head>.
- var myStyle = 'body: {background: red}'
- $('head').append(can.view.mustache('<style>{{myStyle}}</style>')({myStyle: myStyle}))