Hey I was just going through this issue. I solved it by locally installing an earlier version of node. First, I deleted all my node modules and package-lock.json.
Then I installed an earlier version of node locally
npm install --save email@example.com
Then I re-installed all my other node packages
npm install --save drizzle drizzle-react drizzle components
It's okay to define a contract instance every time you need it,
as the ABI and deployed address haven't changed, and your web3 library
or doing anything slow over the network.
I think the efficiency difference is negligible, but if you can create your contract instance once and pass it ...
I solved my issue the day after I posted here, but I wanted to check if it would work properly before posting in here again.
This is the solution that I implemented for my issue.
As I said, I need my users to be able and have as many keys as they want.
In the frontend, they ask for a new Key pair. This is what happens in the background:
var keyPair = ...
In my MetaMask, I go to the setting and choose Connection and add site localhost. In the end, the return value from web3.eth.getAccounts().then(console.log); no longer return empty array. However, it still pops up warning webpackHotDevClient.js:120 ./node_modules/web3-eth-accounts/src/scrypt.js Critical dependency: the request of a dependency is an ...
I was facing the same issue on an old project which was working fine till recent past. Metamask changes are the cause. You have to call the enable function to access the accounts now. The privacy option in the settings have been removed. The DApp has to initiate from its side. Add this piece of code in the console. You will be prompted for a permission. ...