Version 4 Upgrade Guide
Version 4 of React Native Date Picker introduced support for React Native’s new architecture (Fabric + Turbo Modules) while maintaining backward compatibility.What’s New in v4
- Full support for React Native’s new architecture (Fabric + Turbo Modules)
- Requires React Native 0.71 or later for new architecture support
- Backward compatible with older React Native versions using the legacy architecture
Breaking Changes
There are no breaking changes in v4. You can safely upgrade by simply updating the version number in yourpackage.json.
Installation Steps
- Update the package version:
- Install iOS dependencies (skip for Expo projects):
- Rebuild your project:
New Architecture Support
If you’re using React Native 0.71 or later and have enabled the new architecture, the date picker will automatically use Fabric and Turbo Modules. No additional configuration is required. To verify new architecture support is enabled, check that:- Your React Native version is 0.71 or higher
- The
newArchEnabledflag is set totruein your project configuration - The
react-native-date-pickerversion is 4.3.0 or higher
Compatibility
Minimum Requirements:- Xcode >= 11.6
- React Native >= 0.57
- For React Native 0.64: version 0.64.2 or later required
- For Expo: SDK 42 or later (SDK 44.0.4+ for Expo SDK 44)
- For new architecture: React Native 0.71+ and react-native-date-picker 4.3.0+
Migration Checklist
- Update
react-native-date-pickerto version 4.x inpackage.json - Run
pod installfor iOS (skip for Expo) - Rebuild your app for both platforms
- Test all date picker instances in your app
- Verify modal and inline modes work correctly
- Test on both iOS and Android devices
Troubleshooting
If you encounter issues after upgrading:-
Clean build: Remove build artifacts and rebuild
-
Clear metro cache:
-
Verify linking: For React Native < 0.60, ensure the package is properly linked