BboyAkers/simple-dapp-tutorial

Uncaught ReferenceError: MetaMaskOnboarding is not defined at initialize

Closed this issue · 6 comments

Hi, I'm trying to run thru this tutorial, but keep getting the above error in the Dev Console of my browser. I run

sudo npm run serve

the site comes up successfully, except none of the onboarding functions work. I see in the npm status:

<-- [GET] /node_modules/@metamask/onboarding/dist/metamask-onboarding.bundle.js --> 200 OK /node_modules/@metamask/onboarding/dist/metamask-onboarding.bundle.js 56.53 KiB (1.441ms)

But still get the subject error as if metamask-onboarding is not installed. Any tips here as to what is wrong?

Thanks for the help!

I was banging my head against the wall with this bug myself. Are you ready how stupid the answer is?

It's a typo. The function in contracts.js is called "MetamaskOnboarding" not "MetaMaskOnboarding". I.e. no capital M in "Mask".

🤦‍♂️

Kind of defeats the purpose of a tutorial if it is edited so sloppily that it doesn't work... lol

@jefsmk I'll dig into this! Sorry I've been really busy with work and life 😅.

@webhype Hey no need for the rudeness. If you feel the need to critique, do so without snarky comments. Please be constructive and create a PR, I'd love to have more people contribute to this! I have a full-time job, loving wife who I'm blessed to spend time with, continuous learning, Muay Thai Training, and a substantial amount of volunteer work I do in my local community especially with mentorship and helping out local struggling business with dev work due to COVID. I do this for free and out of genuine love to help the community grow. Please mind your comments and lets keep it positive 🙂

Hi @BboyAkers no good deed goes unpunished right?

Thanks for your work on this tutorial, I really mean it. I found it through the Metamask.io site, so the root of this problem is perhaps that they, a certainly hot and swanky start-up in the middle of a tornado of growth, certainly with no lack of funding, is not supporting you with an editor or some kind of 2nd set of eyes, to catch such typos.

So I was being snarky with MetaMask, not with you. Now that I know they are using your labor of love and publish it on their site, ostensibly to make their platform more popular and their investors richer, without even testing it once, it makes me even madder at them lol.

Unless I am missing something, developer support should be a top priority for them and should be substantially funded.

You don't have to reply with inside corporate details, unless you are free to speak about them -- not expecting that, and thanks again for doing this!

@webhype They're doing a ton internally and are really wanting to ramp up even more on dev rel/support! The focus has been a ton of extension stuff on their end along with all their libraries to make sure there is a fantastic experience for end users! Again this is all on me and I personally did this tutorial because I thought it'd be great for developers. They're a team of amazing people who've been very generous with their time, support and more, no greed at all! I did take ownership of this and there have been updates I haven't been keep up with. Again, this is open source, if you see something wrong just make a PR, I'd love to review and work through it with you! We're all community and should be lifting up the ecosystem 🙂. No snarky remarks needed towards them at all, keep it positive🙂. I'll make sure to push some updates very soon!

I created a PR here:

Thank you for the hard work @BboyAkers This is the best tutorial out there.

@daniel-farina Thanks a ton for the PR!! 🙂You are awesome! 🚀