Setup
Installation
- Install the library
npm install react-native-ui-lib
- Install mandatory peer dependencies
npm install react-native-reanimated react-native-gesture-handler
- For iOS, install pods
cd ios && pod install
Note: If you plan to use specific components, check the Optional Dependencies section. Some components may require additional peer dependencies.
- Follow Reanimated setup guide to complete the installation.
Required Dependencies
UILib requires the following peer dependencies for core functionality:
react-native-reanimated
- Follow the Reanimated setup guidereact-native-gesture-handler
These packages are essential for animations and gesture handling capabilities.
Optional Dependencies
UILib supports additional features through optional dependencies. These packages are required only when using specific components:
Package | Required For |
---|---|
@react-native-community/blur | Card component's blur effects |
@react-native-community/datetimepicker | Date/time picker components |
@react-native-community/netinfo | Network connectivity features |
react-native-haptic-feedback | Haptic feedback functionality |
react-native-svg | SVG-based components |
react-native-shimmer-placeholder | Shimmer loading effects |
react-native-linear-gradient | Gradient-based components |
moment | Date manipulation utilities |
Install only the dependencies you need based on the components you plan to use in your application.