Skip to content

Partial inside partial breaks? #587

@doda-zz

Description

@doda-zz

I have a partial:

{{#each this}}
    {{#each events}}
      {{> anotherPartial matchTime}}
    {{/each}}
{{/each}}

The contents of anotherPartial being equivalent to

{{minutes}}

This breaks in my browser with:

Cannot read property 'minutes' of undefined

however using a debug partial which console.logs the context shows that indeed every time matchTime is a proper object and not undefined. Factoring the code of the partial like so:

{{#each this}}
    {{#each events}}
      {{matchTime.minutes}}
    {{/each}}
{{/each}}

has made it work ... what is going on here?

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions