While running ReactNative Android app getting the below Exception and also while Bundle, getting the same exception.
react-native bundle --platform android --dev false --entry-file index.js --bundle-output android/app/src/main/assets/index.android.bundle --assets-dest android/app/src/main/res/
Unable to resolve module DatePickerIOS
from Project_Path/node_modules/react-native/Libraries/react-native/react-native-implementation.js
: Module DatePickerIOS
does not exist in the Haste module map
Kindly help me to resolve this.
Package.json: "dependencies": { "react": "16.3.1", "react-native": "0.55.2", "react-native-calendars": "1.17.7", "react-native-carousel-view": "0.5.1", "react-native-confirmation-code-input": "1.0.4", "react-native-dash": "0.0.8", "react-native-elements": "0.19.1", "react-native-fbsdk": "0.7.0", "react-native-google-places-autocomplete": "1.3.6", "react-native-google-sign-in": "1.0.16", "react-native-i18n": "2.0.12", "react-native-indicators": "0.12.0", "react-native-maps": "0.21.0", "react-native-material-bottom-navigation": "0.9.0", "react-native-material-dropdown": "0.11.1", "react-native-material-ui": "1.22.1", "react-native-modalbox": "1.4.2", "react-native-searchbar": "1.14.0", "react-native-sensitive-info": "5.1.0", "react-native-splash-screen": "3.0.6", "react-native-vector-icons": "4.6.0", "react-navigation": "1.5.11", "react-native-tab-view": "0.0.77", "react-native-global-props": "1.1.3" }
Terminate the process in the Metro bundler terminal window, and then as pointed out in the comments run npm start -- --reset-cache
What happened with me for this problem,
I encountered this problem twice,
first time i mistakenly imported a js package when it was not installed, it resolved by removing that mistaken import statement
second time i was trying to install 'react-native-modal-overlay' package, and instead of using npm install, i used yarn add react-native-modal-overlay,
and I started getting this problem
tried all steps i could find on net, but not resolved, finally, I took a fresh install of repository in another package, -----then also the build failed, t
-- then i ran npm cache clean, ( the result asked to run command 'npm install --cache /tmp/empty-cache' -- i ran this command, and then tried to make build it succeeded
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With