react-native-search-select
v5.0.2
Published
An animated searchbar component so you can search and select objects
Downloads
177
Maintainers
Readme
:information_source: About the project
This project was made for my final paper in the Computer Science course at UFES (Federal University of Espírito Santo). Please leave a STAR at the repository and contribute to the library.
:rocket: Getting Started
Install react-native-vector-icons along with the icon sources you want to use. In the main example, we use the
Ionicons
source. You can browse all available icon sources and their icons here. If you're unsure which sources you'll need, consider installing all icon sources to cover potential requirements.Install a library to handle responsiveness. The usage examples rely on react-native-responsive-screen. You can install it using
$ yarn add react-native-responsive-screen
or$ npm install react-native-responsive-screen
If you prefer another way to handle responsiveness, feel free to skip this step. However, you will need to adapt the usage example you choose to match your setup.Install this library. You can use
$ yarn add react-native-search-select
or$ npm install react-native-search-select
:information_source: Usage
Create a folder in your project at
src/components/SearchSelect
and add a new file namedindex.js
inside this folder.Choose one of the usage examples from the usage examples, and copy the code into
src/components/SearchSelect/index.js
. You can use any of the examples as a starting point based on your needs (e.g., single-select, multi-select, paginated list).Import the
SearchSelect
component into your code and use it as follows:import SearchSelect from './src/components/SearchSelect'; const App = () => { return ( <SearchSelect placeholder="Search for options" // Other props /> ); }; export default App;
:memo: License
This project is under the MIT license. See the LICENSE for more information.