8 Tips For Writing Better V-For Loops With Vue 3

preview_player
Показать описание

In this video we explore 8 tips for writing better v-for loops that align with vue's best practices.
-----------------------------------------------------------------------------------------------------
Join my channel to support me to continue doing what I love!
-----------------------------------------------------------------------------------------------------
Helpful Reference's:
-----------------------------------------------------------------------------------------------------
-------------------------------------------------------------------------------------------------------
Timestamps:
0:00 Introduction
0:20 What is a v-for loop?
1:22 Tip 1 - use :key attribute
2:24 Tip 2 - v-for loop with an object
3:28 Tip 3 - v-for loop with range (number)
4:17 Tip 4 - v-for loop with template tag
4:33 Tip 5 - no v-if with v-for
5:23 Tip 6 - use computed properties for filtered data
6:16 Tip 7 - access the index
6:52 Tip 8 - avoid using the index for :key
-------------------------------------------------------------------------------------------------------
#vue #vue3 #vuevforloop
Current Subscribers: 8,169
Рекомендации по теме
Комментарии
Автор

Apologize in advance for some spelling errros in a few of the slides, lol 😅

JohnKomarnicki
Автор

at 6:12 if people is an array how did you access the 'age ' property without using index ?

Troy-olfk
Автор

interesting, didn't know using the index of the loop as the key was bad, always thought it was ok since it was gonna be unique

tannercampbell
Автор

Why all those typos? Attriubute, ojbect, componet geez also the font type is annoying

davidemmanuel