Closed gbaasch closed 6 years ago
Basically it's https://github.com/catamphetamine/react-phone-number-input#module-not-found-error-cant-resolve-libphonenumber-jsmetadatamin
In short, your bundler doesn't resolve *.json
file extension.
If you're using Webpack, see the link for the fix.
Otherwise name your bundler.
Did you find a fix for this? I have .json
in my resolved extensions list but still getting this while running snapshot tests for components that import libphonenumber-js
for validation.
when importing
import Phone from 'react-phone-number-input';
I get the following error
Can't resolve 'libphonenumber-js/metadata.min' in '/Users/Gaby/Documents/react-app/node_modules/react-phone-number-input/modules'
I've tried installing and upgrading dependencies with no luck. Using React 16