Web3Auth.io x Moralis: "@web3auth/web3auth" not installed, please install

Follow up:

  • cloned @0xprof git, performed yarn install, then yarn start: web3auth integration works fine
  • cloned @0xprof git, changed version of react-scripts to 5.0.0 in package.json, performed yarn install, then yarn start: web3auth not installed error
    In both cases modifed Moralis serverUrl and appId and Web3Auth clientId with mine.
    Seems to me that something breaks up when using webpack 5

yes, some of moralis dependencies doesn’t work well with webpack 5, but moralis does.
it seem web3auth also doesn’t work well, probably something they will update in the furture

glad you are all sorted out and also @chad125 should be too

I ran your git project with my clientId without issue. Still unable to get it working in my project, though my code is virtually identical. Tried different react-scripts version, yarn instead of npm, still no go. Clicking my button throws:
Uncaught (in promise) Error: "@web3auth/web3auth" not installed, please install at Web3AuthConnector.js:147:21 at tryCatch (runtime.js:63:40) at Generator.invoke [as _invoke] (runtime.js:294:22) at Generator.next (runtime.js:119:21) at asyncGeneratorStep (asyncToGenerator.js:5:20) at _next (asyncToGenerator.js:27:9) at asyncToGenerator.js:34:7 at new Promise (<anonymous>) at new Wrapper (export.js:18:24) at Web3Auth3.activate (asyncToGenerator.js:23:12)

I’ll probably just leave it out of the project at this point

*Vite(2.8) React App

Maybe issues with package lock? Or clear modules and install everything again. Or build project again with the working example as a base. It’s not always seamless going from/to v5/v4.

Eventually these tools should update to be v5 compatible so probably easier to wait unless you really need it implemented in your project now.

Yes I tried package and module removal as well. I’ll just leave it out of this project, or at least for now, but ok walking away with a thorough understanding of web3auth for the future.

Hi @alex, thanks for helping. i think that you’re right: I will skip this and go without Web3Auth integration waiting for updates. I’ll keep this open for the record and will update it if and when I’ll work it out

@alex @chad125 @B.One This is an issue with react script (it isnt actually an issue), but looks like web3Auth is most stable with react script 4, so if you plan on integrating web3Auth, it is advisable you use react script 4, This issue is due to the react script as outlined above

*I ran new builds with react-script 4 as well as 5 and issues remained the same, no worries. Thanks for digging in a bit on this though.

sure, feel free to check the working demo of moralis web3auth
(https://moralisweb3authtest.netlify.app/)

Hello guys,

It works if you use the CDN link.

I’ve just tested it with my app.html (I’m using sveltekit)