### Start Metro Packager for Example App
Source: https://github.com/peter-olom/rn-select/blob/main/CONTRIBUTING.md
This command initiates the Metro bundler, which is essential for running the example application. It should be executed from the project's root directory to enable live reloading and development server functionality.
```sh
yarn example start
```
--------------------------------
### Run Example App on iOS Simulator/Device
Source: https://github.com/peter-olom/rn-select/blob/main/CONTRIBUTING.md
This command builds and launches the example application on an iOS simulator or a connected iOS device. It requires an iOS development environment with Xcode installed.
```sh
yarn example ios
```
--------------------------------
### Run Example App on Android Device/Emulator
Source: https://github.com/peter-olom/rn-select/blob/main/CONTRIBUTING.md
This command builds and launches the example application on a connected Android device or emulator. It requires a properly configured Android development environment.
```sh
yarn example android
```
--------------------------------
### Run Example App on Web Browser
Source: https://github.com/peter-olom/rn-select/blob/main/CONTRIBUTING.md
This command builds and serves the example application for web platforms, allowing it to be viewed in a web browser. It's useful for testing web compatibility and responsiveness.
```sh
yarn example web
```
--------------------------------
### Install Project Dependencies with Yarn
Source: https://github.com/peter-olom/rn-select/blob/main/CONTRIBUTING.md
This command installs all required dependencies for the rn-select monorepo project, leveraging Yarn workspaces. It must be run from the root directory to set up the development environment.
```sh
yarn
```
--------------------------------
### Install React Native Select Component
Source: https://github.com/peter-olom/rn-select/blob/main/README.md
Instructions for adding the `@devrue/rn-select` package to your project using yarn or npm.
```Shell
yarn add @devrue/rn-select
```
```Shell
npm install @devrue/rn-select
```
--------------------------------
### Publish New Version to npm
Source: https://github.com/peter-olom/rn-select/blob/main/CONTRIBUTING.md
This command uses `release-it` to automate the process of publishing new versions of the library to npm. It handles tasks like bumping the version based on semver, creating tags, and generating releases.
```sh
yarn release
```
--------------------------------
### Project Scripts Reference
Source: https://github.com/peter-olom/rn-select/blob/main/CONTRIBUTING.md
A reference list of common `yarn` scripts available in the project's `package.json` file, detailing their purpose and usage for various development tasks.
```APIDOC
yarn: setup project by installing dependencies.
yarn typecheck: type-check files with TypeScript.
yarn lint: lint files with ESLint.
yarn test: run unit tests with Jest.
yarn example start: start the Metro server for the example app.
yarn example android: run the example app on Android.
yarn example ios: run the example app on iOS.
```
--------------------------------
### Run Unit Tests with Jest
Source: https://github.com/peter-olom/rn-select/blob/main/CONTRIBUTING.md
This command executes the project's unit tests using Jest. Running tests is crucial for verifying the correctness of code changes and preventing regressions before submitting a pull request.
```sh
yarn test
```
--------------------------------
### Basic Usage of React Native Select Component
Source: https://github.com/peter-olom/rn-select/blob/main/README.md
Demonstrates how to import and use the `Select` component with a simple array of options in a React Native application.
```JavaScript
import { Select } from '@devrue/rn-select';
export function App() {
const pets = [
['cat', 'Cat'],
['dog', 'Dog'],
['horse', 'Horse'],
['fish', 'Fish'],
]
return
}
```
--------------------------------
### Lint Code with ESLint
Source: https://github.com/peter-olom/rn-select/blob/main/CONTRIBUTING.md
This command executes ESLint to check the project's code for style and quality issues. It helps maintain code consistency and adherence to predefined coding standards.
```sh
yarn lint
```
--------------------------------
### Perform TypeScript Type Checking
Source: https://github.com/peter-olom/rn-select/blob/main/CONTRIBUTING.md
This command runs TypeScript to perform static type checking on the project's source code. It helps ensure type safety, catch potential errors early, and maintain code quality.
```sh
yarn typecheck
```
--------------------------------
### React Native Select Component Common Props API Reference
Source: https://github.com/peter-olom/rn-select/blob/main/README.md
Detailed API reference for the common properties of the `rn-select` component, outlining each prop's name, inferred type, description, and default value. This includes configuration for placeholders, list behavior, search functionality, styling, and custom rendering.
```APIDOC
rn-select Component Props:
placeholder: string (Default: None)
Placeholder text when no option is selected.
listTitle: string (Default: None)
Title for the options list.
searchPlaceholder: string (Default: None)
Placeholder text for the search input.
searchPlaceholderTextColor: string (Default: None)
Text color for the search input placeholder.
showSelectionCount: boolean (Default: true)
Flag to show the count of selected items.
options: Array<[key, value]> (Default: Required)
Array of options.
reverse: boolean (Default: false)
Flag to reverse option and check mark position.
selectionEffectColor: string (Default: None)
Color for selection effect.
optionsScrollIndicator: boolean (Default: true)
Flag to show scroll indicator for options.
emptyOptionsPlaceholder: string (Default: 'No Options')
Placeholder text when options is empty.
emptySearchMsg: string (Default: 'No options')
Message when search results are empty.
value: string | Array (Default: None)
Currently selected value(s).
clearable: boolean (Default: true)
Flag to enable clearing of selection.
disabled: boolean (Default: false)
Flag to disable the component.
searchable: boolean (Default: true)
Flag to enable searching.
createable: boolean (Default: false)
Flag to enable creating new items.
avoidBottom: boolean (Default: None)
Avoid options from being hidden by browser window height or position.
onCreateItem: function (Default: None)
Callback when a new item is created.
onChangeInput: function (Default: None)
Callback when input value changes.
renderAnchor: function (Default: None)
Custom rendering for anchor component.
renderSearch: function (Default: None)
Custom rendering for search component.
renderOption: function (Default: None)
Custom rendering for option component.
optionDivider: React.Component (Default: None)
Custom component for option divider.
selectStyle: object (Default: None)
Styles for the select container.
selectPlaceholderTextStyle: object (Default: None)
Styles for the placeholder text.
selectTextStyle: object (Default: None)
Styles for the select text.
selectPillTextStyle: object (Default: None)
Styles for the select pill text.
selectPillRemoveContainerStyle: object (Default: None)
Styles for the select pill remove container.
selectPillRemoveIconStyle: object (Default: None)
Styles for the select pill remove icon.
selectIconStyle: object (Default: None)
Styles for the select icon (close & expand).
searchContainerStyle: object (Default: None)
Styles for the search container.
searchInputStyle: object (Default: None)
Styles for the search input.
searchBackIconStyle: object (Default: None)
Styles for the search back icon.
searchClearIconStyle: object (Default: None)
Styles for the search clear icon.
statsTextStyle: object (Default: None)
Styles for the stats text.
optionListContainerStyle: object (Default: None)
Styles for the options list container.
optionListStyle: object (Default: None)
Styles for the options list.
optionContainerStyle: object (Default: None)
Styles for the option container.
optionTextStyle: object (Default: None)
Styles for the option text.
optionCheckColors: object (Default: None)
Colors for option checkmark.
emptyTextStyle: object (Default: None)
Styles for the empty text.
```
--------------------------------
### Fix ESLint Formatting Errors
Source: https://github.com/peter-olom/rn-select/blob/main/CONTRIBUTING.md
This command automatically attempts to fix common formatting and style issues identified by ESLint. It's a convenient way to quickly resolve linting warnings and ensure code consistency.
```sh
yarn lint --fix
```
--------------------------------
### React Native Select Multi Select Props API
Source: https://github.com/peter-olom/rn-select/blob/main/README.md
API documentation for props specific to the multi-select mode of the React Native Select component, detailing their purpose and types.
```APIDOC
Prop: multi
Description: Flag indicating multiselect mode
Type: boolean
Default: true
Prop: value
Description: Currently selected values
Type: Array
Default: None
Prop: onChangeValue
Description: Callback when values change
Parameters: Receives Array
Default: None
```
--------------------------------
### React Native Select Single Select Props API
Source: https://github.com/peter-olom/rn-select/blob/main/README.md
API documentation for props specific to the single-select mode of the React Native Select component, detailing their purpose and types.
```APIDOC
Prop: value
Description: Currently selected value
Type: string
Default: None
Prop: onChangeValue
Description: Callback when value changes
Parameters: Receives string
Default: None
```
=== COMPLETE CONTENT === This response contains all available snippets from this library. No additional content exists. Do not make further requests.