DEV Community

Discussion on: Hands-on Vue.js for Beginners (Part 5)

Collapse
 
dragz profile image
Roy Dragseth

Hi Marina. I can only join the praise you get for this tutorial. It is one of the best I've read in a long time. Thanks!

Two comments on the code example in this section:

I was slightly confused until I discovered the implicit conversion from camelcase to kebabcase and thus did not understand that 'gameData' in the component declaration corresponds to :game-data in the game-card tag.

Also, the game variable name is used in different contexts. Initially I thought it had to be the same in both the v-for loop and the component declaration, but after toying with the source code it became clear that game in data() is unrelated to the game looping index in v-for. (Pretty obvious in hindsight)

Both these things might be part of the folk-wisdom, but for a newbie like me it threw me off the track for 15 minutes.

Again, thanks for a great tutorial!

Collapse
 
marinamosti profile image
Marina Mosti

Roy, thanks for your kind words :) Nice catch! It's sometimes hard to look at all the angles where someone can trip on, but your input is super valuable. Hopefully, it also helps more people that got tripped up by the same thing