I have the component react-native-modal-datetime-picker
in my React Native project. It's throwing the following error:
error: bundling failed: Error: Unable to resolve module '@react-native-community/datetimepicker' from 'node_modules/react-native-modal-datetime-picker/src/DateTimePickerModal.android.js: @react-native-community/datetimepicker could not be found within the project.
It seems that there's a reference in the react-native-modal-datetime-picker
module to the @react-native-community/datetimepicker
module. I've never run into a scenario before where I had to manually add a dependency of another dependency. Does anyone have any insight on why this is happening?
Dependency injection (DI) is a pattern where components necessary for your code to run are hot-swappable. This means that your dependencies are not hard-coded in your implementation and can change as your environment changes.
see the github
you need to run this:
expo install react-native-modal-datetime-picker @react-native-community/datetimepicker
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