Click in order · Vue.js course · Module 2: Template Syntax

v-show Syntax with Toggle

Arrange the syntax: first the toggle button, then the element with v-show below it:

Items to click

  • "isVisible = !isVisible">
  • Toggle</button>
  • <button @click=
  • <div v-show="isVisible">Panel</div>
Show the answer

Correct order:

  1. <button @click=
  2. "isVisible = !isVisible">
  3. Toggle</button>
  4. <div v-show="isVisible">Panel</div>