Replies: 1 comment
-
It's true, it's pretty confusing. I'm not sure why it was done this way. Related: #1759 |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Does anyone know why handlebar used [] for quoting, not following the JavaScript notation when using the dot notation ?
e.g. the JavaScript ‘city[item.cityid].name’ will lookup he city by the items cityid. In handlebar, This will be interpreted as ‘city[“item.cityid”][“name”]’.
I know that the explicit lookup can perform the task.
We use handlebar to allow customization of reports, and many users are repeatedly making the mistake of assuming that the [] will be evaluated, based on their experience with JavaScript, and the similarities between handlebars and javascript expressions.
Beta Was this translation helpful? Give feedback.
All reactions