You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Error: Unable to resolve module events from /matic/node_modules/@ethereumjs/common/dist.browser/index.js: events could not be found within the project or in these directories
Hint
created a new react-native project using npx react-native init MyApp
As we debug your project repo and we found that react-native is not running on top of node(run on javascript core) that's why some of the packages won't available. So, you need to install those packages manually by yourself in your project and the issue will be resolved. The steps are provided below for your reference.
Steps:
npm i assert
npm i events
npm i stream
npm i react-native-crypto
npm i react-native-randombytes
react-native link react-native-randombytes
npm i --save-dev tradle/rn-nodeify
./node_modules/.bin/rn-nodeify --hack --install
Describe the bug
Error: Unable to resolve module events from /matic/node_modules/@ethereumjs/common/dist.browser/index.js: events could not be found within the project or in these directories
Hint
created a new react-native project using
npx react-native init MyApp
installed
@maticnetwork/maticjs
@maticnetwork/maticjs-ethers
@maticnetwork/maticjs-web3
imported and use web3 plugin
The text was updated successfully, but these errors were encountered: