Hello, so when I try to import the npm package called “yahoo-finance-data” into my application, I’m getting this error, if I install the package but I don’t import it then I get no error:
Unable to resolve module `os` from `/Users/*/my-app/node_modules/yahoo-finance-data/node_modules/request-promise/lib/rp.js`: Module does not exist in the module map
This might be related to https://github.com/facebook/react-native/issues/4968
To resolve try the following:
1. Clear watchman watches: `watchman watch-del-all`.
2. Delete the `node_modules` folder: `rm -rf node_modules && npm install`.
3. Reset Metro Bundler cache: `rm -fr $TMPDIR/react-*` or `npm start -- --reset-cache`.
ABI22_0_0RCTFBQuickPerformanceLoggerConfigureHooks
ABI23_0_0RCTFBQuickPerformanceLoggerConfigureHooks
<redacted>
<redacted>
<redacted>
<redacted>
<redacted>
CFRunLoopRunSpecific
GSEventRunModal
UIApplicationMain
Exponent
<redacted>
I’m importing it like this:
import YahooFinanceAPI from "yahoo-finance-data";
I already tried doing everything on the steps listed, already did around 10 different solutions found on Github, and restarted my computer but still no luck, the problem also happens when I try it on Snack (https://snack.expo.io/H181pRaQG) do anybody have a solution?