pmlopes / yoke

Yoke is a middleware framework for Vert.x
http://pmlopes.github.io/yoke/
Apache License 2.0
157 stars 44 forks source link

yoke handlebars.java and block/partial handling in 1.0.7 #88

Closed ghost closed 10 years ago

ghost commented 10 years ago

just trying to upgrade to yoke 1.0.7, with its changes in the template area.

For some reason, I now seem to have to supply a {{#partial "foo" }} in the "child" template for any {{#block "foo" }} in the "parent" template [1], not just the ones I actually wanted to override, or it goes and tries to locate a foo.hbs file for some reason and then errors out. That doesn't seem right as per [1]. Pretty sure the same partial inheritance pattern was working with 1.0.6.

Haven't split out a simple test case exhibiting the issue yet, probably should...

[1] http://jknack.github.io/handlebars.java/reuse.html

ghost commented 10 years ago

Haven't split out a simple test case exhibiting the issue yet, probably should...

Done: https://github.com/dgoldensquared/yoke-issue-88

pmlopes commented 10 years ago

Thanks for your sample, indeed i've a bug there. The big issue was that before the template loader was not implemented and I've implemented it for 1.0.7, apparently I did not read the spec properly where it says that missing files are allowed and in that case the block body is used...

I am on it...

pmlopes commented 10 years ago

It has been fixed in the 2.x branch