I'm building a component that has a list of a custom object. When user does something specific on this component, some background work is done so that each item on this list can receive some attributes of country codes, like us
for USA and ge
for Germany.
I tried to save a component with the following markup, and got an error instead:
[ERROR]: expecting an identifier, found 'ge' at column 6 of expression: item.ge != undefined: Source
My code is as follows:
...
<li>
<button class="slds-button slds-button_neutral">
<span class="slds-m-right--small">
<div>
<aura:if isTrue="{!item.ge != undefined}">
{!item.ge}
<aura:set attribute="else">
0
</aura:set>
</aura:if>
</div>
</span>
<img src="{!$Resource.famfamfamflagpack + '/png/de.png'}"></img>
</button>
</li>
...
And there are more elements on this HTML List, that have the same markup, but with different country codes, and I can only save when ge
isn't on the list.
Is this a bug? For now I guess my best workaround is to use de
instead, which is fine by me. But it's really weird not to be able to save the component because of an attribute.