I'm currently working with an EmberJS application and I'm wondering how to make an the <head> a partial. I've tried adding {{render 'shared/head'}} but it doesn't get compiled by Ember.
What I currently have right now:
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<title>EmberApp</title>
<meta name="description" content="">
<meta name="viewport" content="width=device-width, initial-scale=1">
{{content-for 'head'}}
<link rel="stylesheet" href="assets/vendor.css">
<link rel="stylesheet" href="assets/whole-new-home.css">
{{content-for 'head-footer'}}
</head>
What I'm hoping to achieve:
<!-- app/index.html -->
...
<head>
{{render 'shared/head'}}
{{content-for 'head'}}
<link rel="stylesheet" href="assets/vendor.css">
<link rel="stylesheet" href="assets/whole-new-home.css">
{{content-for 'head-footer'}}
</head>
...
<!-- app/templates/shared/_head.hbs -->
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<title>{{appName}}</title>
<meta name="description" content="">
<meta name="viewport" content="width=device-width, initial-scale=1">
Aucun commentaire:
Enregistrer un commentaire