s3e40 alternate v-for in template

This commit is contained in:
Tyrel Souza 2018-04-13 23:03:06 -04:00
parent f5d55427cb
commit 24a8cc7559
No known key found for this signature in database
GPG Key ID: 5A9394D4C30AEAC0

View File

@ -12,6 +12,11 @@
({{i+1}}) {{ ingredient }} ({{i+1}}) {{ ingredient }}
</li> </li>
</ul> </ul>
<template v-for="(ingredient, index) in ingredients">
<h1>{{ingredient}}</h1>
<p>{{index}}</p>
</template>
</div> </div>
<script src="app.js" charset="utf-8"></script> <script src="app.js" charset="utf-8"></script>
</body> </body>