Skip to content

Commit 32f812f

Browse files
authored
Revert "Use keyed loop (#1767)"
This reverts commit e9c3020.
1 parent 0959018 commit 32f812f

File tree

1 file changed

+4
-6
lines changed

1 file changed

+4
-6
lines changed

src/v2/guide/index.md

+4-6
Original file line numberDiff line numberDiff line change
@@ -151,9 +151,7 @@ There are quite a few other directives, each with its own special functionality.
151151
``` html
152152
<div id="app-4">
153153
<ol>
154-
<li v-for="todo in todos"
155-
:key="todo.id"
156-
>
154+
<li v-for="todo in todos">
157155
{{ todo.text }}
158156
</li>
159157
</ol>
@@ -164,9 +162,9 @@ var app4 = new Vue({
164162
el: '#app-4',
165163
data: {
166164
todos: [
167-
{ id: 1, text: 'Learn JavaScript' },
168-
{ id: 2, text: 'Learn Vue' },
169-
{ id: 3, text: 'Build something awesome' }
165+
{ text: 'Learn JavaScript' },
166+
{ text: 'Learn Vue' },
167+
{ text: 'Build something awesome' }
170168
]
171169
}
172170
})

0 commit comments

Comments
 (0)