I replaced some repeating code in my file with a partials, but now the call of an relative part is not working anymore.
I have this data-structure:
var data = { staff: [
{"name": "Alan"},
{"name": "Bettina"}
],"company": "Rad, Inc."};
The original template looks like this:
<script id="first_template" type="text/x-handlebars-template">
{{#each staff}}
<li>Name: {{name}} , Company: {{../company}}</li>
{{/each}}
</script>
I changed it like this to use a partial:
<script id="list-partial" type="text/x-handlebars-template">
<li>Name: {{name}} , Company: {{../company}}</li>
</script>
<script id="second_template" type="text/x-handlebars-template">
{{#each staff}}
{{> list}}
{{/each}}
</script>
In the example with the partial the company name does not get rendered. I put a working example on jsfiddle: http://jsfiddle.net/staeff/qwms6h2b/
Does anyone see, why it is not working, what I am trying to do?