-
-
Notifications
You must be signed in to change notification settings - Fork 384
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Dynamic Partials #375
Comments
Updated - the |
Hi @karlhorky I'm sorry but don't get how the lookup helper works and what impact it has inside the dynamic partial. Can you add an example? Thanks |
Updated the original post again with an example of the |
But I think the |
Thanks @jknack! |
no problem and thank you for helping me to identify missing features of handlebars.java vs handlebars.js I will push to maven central today, but I'm sure new release will be available tomorrow. |
Glad to help :) |
@karlhorky in the next few days, I'm going to release 3.0.0 is there any other pending js feature that we are missing? (compared to handlebarsjs 3.0.0) thanks |
Actually, from our side, I haven't needed anything that's missing since Handlebars.java Maybe anything else to be found here? Thanks for your hard work! |
Also check a bit earlier in the release notes - one of my issues was actually about a feature introduced in Handlebars.js |
I don't get how i can use Dynamic Partials with Handlebars.java. i've tried
and
where |
here are some unit test that might help: https://github.com/jknack/handlebars.java/blob/master/handlebars/src/test/java/com/github/jknack/handlebars/i375/Issue375.java also, make sure you don't have a |
fortunately it was only a typo in the question! thank you for the really quick help |
As mentioned in #349, dynamic partials were added to Handlebars.js in handlebars-lang/handlebars.js#941. They are invoked using the following syntax.
In order to use context variables, Handlebars.js uses the lookup helper like this:
However, the stringFormat helper looks like a viable alternative in Handlebars.java:
The text was updated successfully, but these errors were encountered: