react-smart-checkbox
![npm version](https://badge.fury.io/js/react-smart-checkbox.svg)
Installation:
npm i -P react-smart-checkbox
yarn add react-smart-checkbox
How to use:
import ReactSmartCheckbox from 'react-smart-checkbox'
<ReactSmartCheckbox
name='fruits'
options={['orange', 'apple', 'banana']}
/>
Read more below about component's additional attributes ↓
attribute | type | required |
---|
name | string | true |
options | array | true |
initialValues | array | false |
onChange | func | false |
- initialValues should pass array to check any child(s) on componentWillMount hook triggers
- onChange is callback function and returns checked childrens array