MCPcopy Create free account
hub / github.com/reactstrap/reactstrap / onCheckboxBtnClick

Method onCheckboxBtnClick

types/reactstrap-tests.tsx:393–401  ·  view source on GitHub ↗
(selected: number)

Source from the content-addressed store, hash-verified

391 }
392
393 onCheckboxBtnClick(selected: number) {
394 const index = this.state.cSelected.indexOf(selected);
395 if (index < 0) {
396 this.state.cSelected.push(selected);
397 } else {
398 this.state.cSelected.splice(index, 1);
399 }
400 this.setState({ cSelected: [...this.state.cSelected] });
401 }
402
403 render() {
404 return (

Callers 1

renderMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected