Subscribe on changes!

V-if not working properly

avatar
Apr 12th 2022

Version

3.2.31

Reproduction link

github.com

Steps to reproduce

create a variable name showsubmenu:false

  <i class="fa-solid fa-caret-down down-arrow-icon" v-if="showsubmenu"></i>
  <i class="fa-solid fa-caret-right down-arrow-icon" v-else></i>

  <div class='sub-menu' v-if="showsubmenu"></div>

if we toggle the variable it shows the error

What is expected?

Toggle should work on v-if condition

What is actually happening?

Instead of toggle it is showing Error