Skip to content

Commit 40a5762

Browse files
bind this
1 parent 52bbce0 commit 40a5762

File tree

2 files changed

+1
-6
lines changed

2 files changed

+1
-6
lines changed

ep12-make-done-really-work/app/components/App.jsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ export default class App extends React.Component {
6262
</p>
6363

6464
<DisplayList
65-
handleDone={this.handleDone}
65+
handleDone={this.handleDone.bind(this)}
6666
handleDelete={this.handleDelete.bind(this)}
6767
todos={this.state.todos} />
6868
</div>;

ep12-make-done-really-work/app/components/DisplayItem.jsx

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,11 +2,6 @@ import React from 'react';
22

33
export default class DisplayItem extends React.Component {
44

5-
constructor () {
6-
super();
7-
this.state = { done: false };
8-
}
9-
105
render () {
116
var todo = this.props.todo;
127
var title = todo.title;

0 commit comments

Comments
 (0)