Skip to content

Instantly share code, notes, and snippets.

@parzibyte
Created August 16, 2019 02:28
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save parzibyte/4c4ff617463fc20e29597afacd05ea54 to your computer and use it in GitHub Desktop.
Save parzibyte/4c4ff617463fc20e29597afacd05ea54 to your computer and use it in GitHub Desktop.
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width">
<title>Uso de v-for en Vue.js</title>
<link href="https://stackpath.bootstrapcdn.com/bootstrap/4.3.1/css/bootstrap.min.css" rel="stylesheet" integrity="sha384-ggOyR0iXCbMQv3Xipma34MD+dH/1fQ784/j6cY/iJTQUOhcWr7x9JvoRxT2MZw1T"
crossorigin="anonymous">
</head>
<body>
<main role="main" class="container">
<div class="row">
<div class="col-12" id="app">
<h1>Uso de v-for en Vue.js</h1>
<a href="//parzibyte.me/blog">By Parzibyte</a>
<table class="table">
<thead>
<tr>
<th>Índice</th>
<th>Canción</th>
<th>Artista</th>
</tr>
</thead>
<tbody>
<tr v-for="(cancion, indice) in canciones">
<td>{{indice}}</td>
<td>{{cancion.nombre}}</td>
<td>{{cancion.artista}}</td>
</tr>
</tbody>
</table>
</div>
</div>
</main>
<script src="https://cdn.jsdelivr.net/npm/vue@2.6.10/dist/vue.js">
</script>
<script src="script.js">
</script>
</body>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment