0 votes
in VueJS by
How do you use v-for directive with a range in VueJS?

1 Answer

0 votes
by
You can also use integer type(say 'n') for v-for directive which repeats the element many times.

<div>

  <span v-for="n in 20">{{ n }} </span>

</div>

It displays the number 1 to 20.

Related questions

0 votes
asked Feb 4, 2020 in VueJS by rajeshsharma
0 votes
asked Sep 7, 2023 in VueJS by DavidAnderson
...