mirror of
https://github.com/facebook/react.git
synced 2025-11-01 09:12:30 +00:00
Merge pull request #616 from davidhellsing/patch-1
Backbone example: changed key from Math.random() to todo.cid
This commit is contained in:
@@ -236,7 +236,7 @@ var TodoApp = React.createClass({
|
||||
var todoItems = this.props.todos.map(function(todo) {
|
||||
return (
|
||||
<TodoItem
|
||||
key={Math.random()}
|
||||
key={todo.cid}
|
||||
todo={todo}
|
||||
onToggle={todo.toggle.bind(todo)}
|
||||
onDestroy={todo.destroy.bind(todo)}
|
||||
|
||||
Reference in New Issue
Block a user