injected function not evaluated in undefined parameter
The problem is with injected function, for example if i have template
model: [ { "{{#if hasValue(data)}}": { name: "{{name}}", }, }, { "{{#else}}": undefined, }, ],
if data property exists in model, the evaluation work well, but if transform other data, where property "data" not exists, hasValue not evaluated.
Thank you @mpanichella for the notice. I will look into that.
If I understand it correctly, you inject hasValue function to the SelectTransform and then run the above model with a data object such as { } and the issue is that hasValue is not called.
It seems to me that it might fail on the fact that data is not defined, also it seems that I handle injections poorly. I will try to take a look at that. Did you try to use this.data instead of just simple data?
Also, would you be that kind and provide me with whole snippet of code and expected outcome? Thank you :)