Handlebars-Net/Handlebars.Net

Nested partials does't work with block helpers

DmitryDem opened this issue · 1 comments

Describe the bug

Nested partials does't work with block helpers

Expected behavior:

Nested partials with block helpers should works

Test to reproduce

[Test]
public async Task NestedPartialTest()
{
var universalLinkPartial = "https://www.someuri.com/{{#if language}}es{{else}}en{{/if}}/people";
var linkPeopleAppRegPartial = "{{>link_universal_people language=language}}";

Handlebars.RegisterTemplate("link_universal_people", universalLinkPartial);
Handlebars.RegisterTemplate("link_people_app_registration", linkPeopleAppRegPartial);

var template = "{{#if reg_source}}href=\"{{>link_people_app_registration language=language}}\"{{/if}";
var compiled = Handlebars.Compile(template);

var result = compiled(new {language="es" });

}

My mistake