I'm using React.js and I'm creating a todo app.
The contents are roughly like this code.
class TodoValue extends React.Component{
_onChange(){
console.log("atacked");
}
render(){
return(
<List>
{
this.props.todos.map(function(todo, i){
return <ListItem key={i} primaryText={todo.item} rightIcon={<ActionInfo />} leftCheckbox={<Checkbox onClick={this._onChange.bind(this)} />} />
})
}
</List>
);
}
}
Why can not I find the onChange
function in checkbox?
Input and button to update information are omitted.