javascript - Ember Handlebars Templates in <head> tag -
is possible ember (specifically application template) operate inside head tag in order dynamically change things title tag, meta tags, external css stylesheets , favicon?
if so, clean way of doing this?
in order make work, did created handlebar helpers. example, if want change title views common, here helper.
ember.handlebars.helper('headtitle', function(title) { ember.$('head').find('title').text(title); }, 'title');
now in view template can add helper
{{headtitle 'view header'}}
here jsbin check if working
Comments
Post a Comment