You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The "{{includeContext}}" prints out something, the "{{property2}}" not (although there is data in it)!
When I debug the code I see that the IncludeHelper copies the hashes to the context.data
publicCharSequenceapply(finalStringpartial, finalOptionsoptions) throwsIOException {
// merge all the hashes into the contextoptions.context.data(options.hash);
...
But when the actual data is retrieved in the class "Block"
This method used the 'model' instead of the 'data'. I find this strange, because the IncludeHelper copied the hashes to the data, and not the model!??!
What am I doing wrong? Or is this an issue?
The text was updated successfully, but these errors were encountered:
The include helper is a community donation, see #140
It was added bc in handlebars.js partials with context wasn't supported. Anyway, will check if handlebars.js can or can't have a custom context and update/remove the include helper if necessary.
In the mean while, just use plain partials bc in handlebars.java they work as the Mustache Spec said.
I'm trying to use the includeHelper, but I'm having some troubles.
In my templates I've got something like this:
and in the template "templateName" I'm trying:
The "{{includeContext}}" prints out something, the "{{property2}}" not (although there is data in it)!
When I debug the code I see that the IncludeHelper copies the hashes to the context.data
But when the actual data is retrieved in the class "Block"
The following method of Context is eventually called:
This method used the 'model' instead of the 'data'. I find this strange, because the IncludeHelper copied the hashes to the data, and not the model!??!
What am I doing wrong? Or is this an issue?
The text was updated successfully, but these errors were encountered: