5

My If-Iteration structure is similar to written below

<aura:if isTrue="">
<ul>
  <aura:if isTrue="">
  </aura:if>

  <aura:if isTrue="">
  </aura:if>

  <aura:iteration>
   <li>
   </li>
  </aura:iteration>
</ul>
</aura:if>

Everything goes smoothly but when the above div is rerendered then the below-mentioned error comes

rerender threw an error in 'markup://aura:if'

[Cannot read property 'childNodes' of null] Failing descriptor: {markup://aura:if}

I also tried to wrap in but it does not work. (which was given in this post)

  • Did you find an answer to this? I am still stuck also and have read all similar posts! – dacology Mar 14 '17 at 17:00
  • @dacology, nope. – Kapil Kaushik Mar 15 '17 at 6:55
  • I'm also stuck with this arbitrary error. – kev_panda Mar 21 '17 at 19:19
1

I think you should also try to seperate the aura:if from the aura:iteration using the same technique.

Try something like this:

<aura:if isTrue="">
  <ul>
    <span>
      <aura:if isTrue="">
      </aura:if>
    </span

    <span>
      <aura:if isTrue="">
      </aura:if>
    </span

    <span>
      <aura:iteration>
       <li>
       </li>
      </aura:iteration>
    </span>
  </ul>
</aura:if>

If this does not work, try to determine which aura:if is causing the problem - try to remove the outer and inner aura:if and the aura:iteration statements separately to see if you can alter the rendering behaviour.

| improve this answer | |
-1

You should try something like this

<aura:if isTrue="">
<ul>
<aura:if isTrue="">
</aura:if>

<aura:if isTrue="">
</aura:if>

<aura:iteration>
<span>
  <li>
  </li>
</span>
</aura:iteration>
</ul>
</aura:if>
| improve this answer | |
  • Why would adding a span around the <li> elements make any difference? – Matt Lacey Apr 28 '17 at 5:39

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.