Setting id tag dynamically using vuejs Setting id tag dynamically using vuejs vue.js vue.js

Setting id tag dynamically using vuejs


This should work.

:id="`cv${todo.id}`"

or

v-bind:id="`cv${todo.id}`"

Or do it the old-school way if the browser doesn't support string interpolation:

:id="'cv' + todo.id"

This is essentially a duplicate but I couldn't determine how to escape the backticks in a comment!