[Vuejs]-Concatenate data in Image SRC

0👍

You can set the whole source with vue:

<img v-bind:src="'https://example.io/us/flat/' + index.slice(0,2) + '.png'" />

or shorter

<img :src="'https://example.io/us/flat/' + index.slice(0,2) + '.png'" />

Leave a comment