Skip to content

Commit aebdc36

Browse files
author
lewis617
committed
jianju
1 parent 2ec3933 commit aebdc36

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

todo/src/components/todo.js

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,20 +13,24 @@ export default class Todo extends React.Component{
1313
this.setState({list: list});
1414

1515
}
16+
1617
componentDidMount() {
1718
store.listen(this.onStatusChange.bind(this));
1819
actions.getAll();
1920

2021
}
22+
2123
add(){
2224
var item =this.refs.item.value;
2325
this.refs.item.value='';
2426
actions.add(item);
2527

2628
}
29+
2730
remove(i){
2831
actions.remove(i);
2932
}
33+
3034
render() {
3135
return (
3236
<div>

0 commit comments

Comments
 (0)