-
-
Notifications
You must be signed in to change notification settings - Fork 383
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
Partials with parameters #350
Comments
Seems this card needs to be merged with #349 |
@husayt These partials were actually implemented in v2.0.0. So this is a bit older than v3.0.0 as in the other issue. |
Has this been implemented? This feature is pretty useful. |
Could this be the culprit? |
Thanks @jknack! |
HI, I have a very simple use case where: {{> mypartial label="Value of the label" }} mypartial.hbs.html And it is not working. Do you see any problem with it? Also, can someone show me a working example? |
did you see any error? there are a few unit tests that demonstrate partials param in action. Here is one: https://github.com/jknack/handlebars.java/blob/master/handlebars/src/test/java/com/github/jknack/handlebars/i350/Issue350.java |
Partial parameters require the MapValueResolver.INSTANCE to be registered as resolver in the context. If partial parameters are not passed, this might be the reason. |
Can you support the handlebars.js partial parameters notation? Like in the spec here?
context
index.hbs
dude.hbs
expected output
I saw the
#partial
and#block
helpers here, but I'm working on a project where we would like to keep parity with handlebars.js if possible.The text was updated successfully, but these errors were encountered: