react-native-autocomplete-dropdown-picker
v0.1.2
Published
A fully customizable autocomplete dropdown picker for React Native
Maintainers
Readme
react-native-autocomplete-dropdown-picker
A fully customizable autocomplete dropdown picker for React Native
Installation
import AutocompleteDropdown from 'react-native-autocomplete-dropdown-picker';Usage
import AutocompleteDropdown from 'react-native-autocomplete-dropdown-picker';
// ...
onst data = [
{ value: '1', label: 'Apple' },
{ value: '2', label: 'Banana' },
{ value: '3', label: 'Cherry' },
// Add more items
];
export default function App() {
const [selectedItem, setSelectedItem] = useState(null);
return (
<View style={styles.container}>
<AutocompleteDropdown
data={data}
onSelect={setSelectedItem}
placeholder="Search fruits..."
borderColor="#007bff"
borderWidth={2}
borderRadius={10}
backgroundColor="#f8f9fa"
dropdownBackgroundColor="#ffffff"
itemBackgroundColor="#f0f8ff"
textColor="#333333"
/>
</View>
);
}
const styles = StyleSheet.create({
container: {
flex: 1,
padding: 20,
justifyContent: 'center',
},
});
Contributing
See the contributing guide to learn how to contribute to the repository and the development workflow.
License
MIT
Made with create-react-native-library
