GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — GitHub - BahmanBinary/rnpicker: Most flexible and customizable react native picker

BranchesTags
Open more actions menu

Latest commit

 

History

20 Commits
20 Commits

Folders and files

NameName
Last commit message
Last commit date
__tests__
__tests__
 
 
android
android
 
 
assets/img
assets/img
 
 
components
components
 
 
ios
ios
 
 
storybook
storybook
 
 
.buckconfig
.buckconfig
 
 
.eslintrc.js
.eslintrc.js
 
 
.flowconfig
.flowconfig
 
 
.gitattributes
.gitattributes
 
 
.gitignore
.gitignore
 
 
.npmignore
.npmignore
 
 
.watchmanconfig
.watchmanconfig
 
 
App.js
App.js
 
 
README.md
README.md
 
 
app.json
app.json
 
 
babel.config.js
babel.config.js
 
 
index.js
index.js
 
 
metro.config.js
metro.config.js
 
 
package-lock.json
package-lock.json
 
 
package.json
package.json
 
 

Repository files navigation

RNPicker

Preface

Hello friends! For a while I was looking for a good, customizable Picker for react native but most of these pickers have little flexibility. For example you can't support RTL correctly or use custom component for each picker items.

Documentation

Installation
npm install @bahmanbinary/rnpicker
yarn add @bahmanbinary/rnpicker
APIs
Props
Prop Type Default Description
data {label: string | number, value: string | number, selected?:boolean}[] [] Data for each item
rtl boolean false Enable right to left support
itemComponent React Native Component Wrapper component for each item
itemStyle {} - Custom style applied to each itemComponent
iconComponent React Native Component (props: { iconColor:string, iconSize:number, iconStyle:{} ,...props:any }) Icon component
onSelect ( item:string | number, index:number ) => void - Function that will be executed for each item selected
containerStyle {} - RNPicker container custom style
placeholder string 'Please select' Placeholder
placeholderStyle {} - RNPicker placeholder custom style
iconColor string 'black' Icon color applied to each iconComponent
iconSize number Icon size applied to each iconComponent
iconStyle {} - Custom style applied to each iconComponent
Methods
Method Type Description
dismissPicker () => void Dismiss opened picker
Usage
import React,{Component} from 'react';
import RNPicker from '@bahmanbinary/rnpicker';

export default class Example extends Component{
    render(){
return <RNPicker data=[
	{label:'item 1', value:1},
    {label:'item 2', value:2},
    {label:'item 3', value:3, selected:true},
    {label:'item 4', value:4},
    {label:'item 5', value:5}
]        
        />
    }
}

If this project was useful to you, give it a Star ! ⭐😎😉

About

Most flexible and customizable react native picker

Topics

pickerpicker-componentpickersreact-native-pickerreact-native-pickersreact-native-selectorselectorselectors

Resources

Readme
Activity

Stars

3 stars

Watchers

1 watching

Forks

0 forks
Report repository

Releases

Packages

Used by

Contributors

Languages

You are visitor 01402792 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.