in VueJS by (883 points)
recategorized by

How do you achieve conditional group of elements?

1 Answer

0 votes
by (883 points)

You can achieve conditional group of elements(toggle multiple elements at a time) by applying v-if directive on <template> element which works as invisible wrapper(no rendering) for group of elements. For example, you can conditionally group user details based on valid user condition.

<template v-if="condition">
  <p>Contact Details</p>

Related questions

0 votes
asked Oct 21, 2019 in VueJS by Tate (883 points)