Build Your First dApp! - Moralis Project going live on the 21st of May

In this thread please ask any questions about Moralis Project ‘Build Your First dApp!’ that will be going
live on the 21st of May. We will help right away!

Project video:


Looking forward!

I’ve been doing good so far but something I did messed up my preview page on my local host. Now I am getting some warnings in my terminal. I can post my code from App.js and Coin.js if necessary. I was working on those when it stopped working. I have tried running yarn start again with no luck. It just shows the original themed blank page that we started with. The errors it’s displaying in the terminal are below. Thanks in advance for any help.

Module not found: Can’t resolve ‘magic-sdk’ in ‘C:\Users\crypt\Desktop\Sentiment Dapp\FirstDapp-Starter\node_modules\moralis\lib\browser\Web3Connector’

Line 1:17: ‘useEffect’ is defined but never used no-unused-vars
Line 3:25: ‘Logo’ is defined but never used no-unused-vars

Try installing with yarn add magic-sdk.

You can ignore the bottom two warnings. Similar issue here.

1 Like

Well that installed but still isn’t working. It did say it was successfully installed. If I remove the two unused sections it compiles fine but still won’t display my work so far on the page. I just don’t get it. It was working fine one minute then just stopped. Like I just finished making the first circle and was ready to make the rest. I’m running out of ideas of what it could be.

What errors do you get now in your browser and terminal? It will compile fine with the unused warnings, don’t worry about those. If things stopped working when you added more code then remove those parts temporarily and test to see where the issue lies.

You can also look at the final code here to compare with yours.

1 Like

It doesn’t give any errors now just the unused parts. Comparing the code side by side definitely helped. I finally figured it out. A dang > didn’t get the memo to drop down a few lines I guess lol. But it’s working now. Hopefully I will be posting a completed picture here soon.


I just completed this project, and had a lot of fun creating it! This was my first time using hardhat and actually verifying my smart contract on etherscan. I was facing issues adding Polygon Mumbai to my Metamask so I used Rinkeby instead. Everything in the project seemed to work except two things:

  • Modal styling: not sure why but my modal styling looks different to the video :thinking:

  • Error message alert: if the person tries to vote multiple times or reject the transaction, instead of an alert popping up, the app stops responding, for some reason the async error handling function is being ignored :cry: I don’t know React so no clue how to fix it.

My GitHub Repo:

P.S. I also had the following 3 warnings while running yarn start, but the app works fine despite these so not sure if I am meant to resolve these warnings:

  • Module not found: Can’t resolve ‘magic-sdk’
  • React Hook useEffect has missing dependencies: ‘Moralis.Query’ and ‘getRatio’.
  • React Hook useEffect has a missing dependency: ‘Web3Api.token’.
1 Like

You can compare your code with the final repo. youtube-tutorials/FirsrDapp-Final at main · MoralisWeb3/youtube-tutorials (

For the error handling, to start with you can wrap that code in a try catch block so at least your app won’t break.

  • Module not found: Can’t resolve ‘magic-sdk’
    yarn add magic-sdk should resolve it, but it should be working anyway with this error.

The last two warnings should be ok if that is how it is in the final project.

Unable to deploy the smart contract to the Mumbai network.

I was under the impression that TEST network doesn’t require any MATIC in the wallet.
Is my assumption wrong? What is the workaround?

Appreciate your help and support.

P.S: I am Web 3.0 newbie and in the learning phase.

No you still need native currency to pay for gas fees. Test networks are still like real networks, but you can get ETH, MATIC, etc. for free from faucets.

Here is a faucet you can use: Polygon Faucet

I followed along and completed the App, at first it was working all fine. But for some reason my app went unresponsive, even the connect wallet button doesn’t work. Everything looks all fine, I even tried creating a new server in Moralis but still no luck.

Do you get any errors in console? What did you change in code in between it working and becoming unresponsive? And make sure your server is awake.

Thanks for your help. @alex

I am too facing the same problem. none of my buttons are working ( up , down , info , connectWalllet ). what to do

I am too facing the same problem. none of my buttons are working ( up , down , info , connectWalllet ). i also tried new testnet server on moralis but it didn’t work

Do you get any errors in your browser console? If you have made code changes and the app stops functioning, reload the page.

I followed the Moralis YouTube tutorial to build a market sentiment dapp ( without any knowledge about the Moralis update that removes speedy nodes, testnet servers, etc.

Can someone please suggest alternatives to Moralis for testnet server URL and stuff?

I also have issues with localhost. The first time I did “yarn start”, it reflected all the changes live but from the next time, all i was able to see was a blank dark screen.

Any fixes for this?

Hey guys, Im about 17 mins into this, have completed the MarketSentiment.sol, but I can not see a lot of the files that appear to be there in the video. The first one I have come across is deployMarketSentiment.js. Has anybody got the source code they could send me? would be a great help. Figure i can just add any missing files manually.

Also after I downloaded hardhat, I took the advice from the terminal and ran npm audit fix now there are no vulnerabilities. Should I Re-install it?

Really enjoying the experience so far. Thanks in advance for any help!