Giter VIP home page Giter VIP logo

react-native-bouncy-checkbox-group's Introduction

React Native Bouncy Checkbox Group

Battle Tested โœ…

React Native Bouncy Checkbox Group

npm version npm Platform - Android and iOS License: MIT styled with prettier

React Native Bouncy Checkbox Group

Installation

Add the dependency:

npm i react-native-bouncy-checkbox-group

Peer Dependencies

IMPORTANT! You need install them
"react-native-bouncy-checkbox": ">= 2.1.5"

Usage

Import

import BouncyCheckboxGroup, {
  ICheckboxButton,
} from "react-native-bouncy-checkbox-group";

Fundamental Usage

<BouncyCheckboxGroup
  data={staticData}
  onChange={(selectedItem: ICheckboxButton) => {
    console.log("SelectedItem: ", JSON.stringify(selectedItem));
  }}
/>

Vertical Usage

<BouncyCheckboxGroup
  data={verticalStaticData}
  style={{ flexDirection: "column" }}
  onChange={(selectedItem: ICheckboxButton) => {
    console.log("SelectedItem: ", JSON.stringify(selectedItem));
  }}
/>

Data Format

You MUST follow this data format as ICheckboxButton

[
  {
    id: 0,
  },
  {
    id: 1,
  },
  {
    id: 2,
  },
  {
    id: 3,
  },
];

Example Project ๐Ÿ˜

You can checkout the example project ๐Ÿฅฐ

Simply run

  • npm i
  • react-native run-ios/android

should work of the example project.

Configuration - Props

Fundamentals

Property Type Default Description
data ICheckboxButton[] undefined set the checkboxes as a data
onChange function undefined set your own logic when the group of checkbox is selected
checkboxProps IBouncyCheckboxProps undefined default props for all checkboxes

Customization (Optionals)

You can use all of the customiztion options from the rn bouncy checkbox. You NEED to add the styling and props into the data. Therefore, you can customize each of the checkboxes easily.

Future Plans

  • LICENSE
  • Write an article about the lib on Medium

Author

FreakyCoder, [email protected]

License

React Native Bouncy Checkbox Group is available under the MIT license. See the LICENSE file for more info.

react-native-bouncy-checkbox-group's People

Contributors

srbrahma avatar wrathchaos avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.