Recently our lightning app started failing with a very odd error.

enter image description here I've created a very simple lightning app that reproduces that issue. So it looks like length property is not available anymore for attributes of String type in Winter 20 sandbox.

Is anyone has the same issue? Is it a platform bug or security improvement?

<aura:application extends="force:slds">
<aura:attribute name="sampleString" type="String" default="" />
<aura:if isTrue="{!v.sampleString.length != 0}">


UPD: After some investigation on different sandboxes. Found out this issue is reproduced only on Winter 20 Patch 8.6 The same code works fine on Winter 20 Patch 8.5

1 Answer 1


aura:application was not supporting it from last few months. However, it is supposed to be acting ONLY as a container for lightning component(s). So, you should ideally use all the logic in component and use that component in app.


<aura:application extends="force:slds">
    <c:myComp />


<aura:attribute name="sampleString" type="String" default="asd" />
<aura:if isTrue="{!v.sampleString.length != 0}">
    sampleString.length != 0
<aura:if isTrue="{!v.sampleString.length == 0}">
    sampleString.length == 0
  • that's correct. I've put the code into the lightning app just to simplify steps to reproduce. Originally this error started to appear in the regular aura components.
    – steals
    Oct 9, 2019 at 13:23
  • Do you have any references why lightning app does not support aura:if syntax?
    – steals
    Oct 9, 2019 at 13:24

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .