Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- class EventRowAdmin extends Component {
- constructor(props) {
- super(props);
- this.state = { isChecked: false };
- this.handleChange = this.handleChange.bind(this);
- }
- handleChange(event) {
- this.setState(({ isChecked }) => (
- {
- isChecked: !isChecked
- }
- ));
- console.log(this.state.isChecked);
- }
- render() {
- return (
- <tr id={this.props.id}>
- <td><input onChange={this.handleChange} className="remove-event" type="checkbox" /></td>
- </tr>
- )
- }
- }
Add Comment
Please, Sign In to add comment