Detect id of an DOM element?

Asked

Viewed 69 times

-1

I am developing an application in Vuejs/Quasar and need to discover the id of a certain element using the getElementById, how do I do it in Vuejs??

  • 2

    Vuejs is Javascript. You can use it anyway .getElementById. But it would be interesting to know more about your code to answer better.

  • I’ve already found a solution using (item, index) in the v-for and passing it as a parameter in the capture method.

1 answer

1


In Vue.js if you use v-for you can use the index property.

Browser other questions tagged

You are not signed in. Login or sign up in order to post.