0.1.0 • Published 4 years ago

rnative-radio-buttons v0.1.0

Weekly downloads
3
License
MIT
Repository
github
Last release
4 years ago

Installation

To install a stable release use:

yarn

yarn add rnative-radio-buttons

npm

npm i rnative-radio-buttons --save

Example

import RadioButtons from 'rnative-radio-buttons';

const options = [
  { label: 'Erkek', value: 'E' },
  { label: 'Kadın', value: 'K' },
];

class Index extends Component {
  state = {
    value: 'E'
  };
  
  render() {
    return (
      <RadioButtons
        options={options}
        selected={this.state.value}
        onPress={(value) => {
          return this.setState({ value })
        }}
      />
    )
  }
}