Тёмный

[2022] Web 3 Tutorial - Connect MetaMask Wallet - ReactJS + Ethers.js 

Software Sage
Подписаться 4,1 тыс.
Просмотров 27 тыс.
50% 1

🔗 Connect with us:
▶ Need development services? Head over to software-sage.com
▶ Instagram: / davidrazdev
▶ Check out our reviews: Software Sage LLC on Google: maps.app.goo.g...
▶ Join our Discord Server: / discord
▶ Connect with me on LinkedIn: / davidrazmadze
▶ Visit my Personal Website: davidrazmadze.com
GitHub Repo
github.com/dav...

Опубликовано:

 

1 окт 2024

Поделиться:

Ссылка:

Скачать:

Готовим ссылку...

Добавить в:

Мой плейлист
Посмотреть позже
Комментарии : 43   
@valkeallar7599
@valkeallar7599 2 года назад
Well done! Quick, short, and to the point! :)
@software-sage
@software-sage 2 года назад
Glad you liked it!
@ayushdabral4232
@ayushdabral4232 2 года назад
straight to the point...thank you!
@AyushiGoyal-s1s
@AyushiGoyal-s1s Год назад
everything is fine, but at the end I got an error : 'ethers'.'providers' is not exported from 'ethers' (imported as 'ethers').
@software-sage
@software-sage Год назад
I would look this up on ChatGPT to see what it suggests. Import errors are usually just a matter using the right syntax.
@mateovallejo6539
@mateovallejo6539 2 года назад
Perfect! Hope to see more videos like this one! Would be really good to see how to interact with SC or more functions to obtain balances... Thanks!
@cryptonicchronic8111
@cryptonicchronic8111 2 года назад
holy sheep sh!t this was a smooth clean and fast video right to the point and descriptive, just got a new follower homie thanks for this video
@software-sage
@software-sage 2 года назад
💯
@KMWebverse
@KMWebverse Год назад
how to let user select any account of their own choice? because users can have multiple account
@catreunion
@catreunion 2 года назад
thank you so much for your production! it's very helpful.
@software-sage
@software-sage 2 года назад
You’re welcome glad you enjoyed it
@sayandcode
@sayandcode 8 месяцев назад
Sick beats
@Adam-he8wb
@Adam-he8wb 10 месяцев назад
How can i show just first 3 and last 3 digits in button text once connected?
@software-sage
@software-sage 10 месяцев назад
You’ll need to make a helper function. Get the first 3 digits, add …, then last 3 digits.
@amservices
@amservices Год назад
Can you explain how to connect MetaMask to web3 on IPFS from iPhone?
@software-sage
@software-sage Год назад
I haven’t tried it yet but I can look into it for a future video.
@mauroreis1809
@mauroreis1809 Год назад
The problem in my app that i incorporated this on is that, when the wallet is already connected on the site and i refresh, it does not keep showing me the metamask address, it only works as intended if the wallet is disconnected in the first place
@PasquaFZFinanzas
@PasquaFZFinanzas 2 года назад
Could you make a similar video with react 18?
@software-sage
@software-sage Год назад
Yes I will make an updated video
@investingthelike111
@investingthelike111 2 года назад
Or can I do window.etheruem.request and see if they are using ropsten test network or main net ?
@software-sage
@software-sage 2 года назад
docs.metamask.io/guide/ethereum-provider.html Check the Chain IDs section
@siddhantjain1255
@siddhantjain1255 Год назад
Hello! I'm getting an error that says "ethers is not defined" even though I have installed the lib. Do i need to import it at the top of the file for it to work?
@software-sage
@software-sage Год назад
Yes exactly
@shiuan3037
@shiuan3037 2 года назад
hi how do i shorten the wallet address to make it show like 0xaaaaa....a12d
@software-sage
@software-sage 2 года назад
Try this out: github.com/gpxl-dev/truncate-eth-address/blob/main/src/index.ts
@zelenytypek
@zelenytypek 2 года назад
thanks a lot for this vid. do you also the one with fetching account balance?
@software-sage
@software-sage 2 года назад
Yes I can make one in the future
@asfandamin8170
@asfandamin8170 2 года назад
best got the concept
@Babyak713
@Babyak713 Год назад
npm install ethers is not working tho
@software-sage
@software-sage Год назад
It should be working. Make sure you’re in the right location in the terminal. www.npmjs.com/package/ethers
@mauroreis1809
@mauroreis1809 Год назад
Life saver!
@gorjanilijevski9769
@gorjanilijevski9769 2 года назад
simple and useful tnx
@kareem80s
@kareem80s Год назад
awesome brother
@software-sage
@software-sage Год назад
Thanks ✌️
@1ightning264
@1ightning264 2 года назад
how can i disconnect the wallet ?
@software-sage
@software-sage 2 года назад
Just reload the page using window.reload. Additionally you can store the wallet address using local storage within the browser.
@trram5032
@trram5032 2 года назад
Thank thanks good bro 💝
@software-sage
@software-sage 2 года назад
Welcome
@investingthelike111
@investingthelike111 2 года назад
How do I tell if someone is trying to pay with ropsten or mainnet? Like can I do getsigner() Network = ropsten or mainnet ??
@software-sage
@software-sage 2 года назад
You can checkout the chain id using window.etherem.request({ method: net_version }) docs.metamask.io/guide/ethereum-provider.html#chain-ids
@investingthelike111
@investingthelike111 2 года назад
@@software-sage thanks i figure it out const { chainId } = await provider.getNetwork() console.log("this is chainId" + chainId) if (chainId !== 1){ alert("please change to Metamask to the Mainnet to make payment" ) return } this solves my problem of people trying to pay with test eth,
@showolesheriff
@showolesheriff Год назад
will window.ethereum works on mobile
@software-sage
@software-sage 11 месяцев назад
It should if the user has MetaMask on their phone
Далее
Connection MetaMask to a ReactJS Web App
30:20
Просмотров 7 тыс.
Web3.js vs Ethers.js: Which is best?
26:02
Просмотров 26 тыс.
ТАРАКАН
00:38
Просмотров 1,6 млн
Ethereum Dapp: Connect React app to MetaMask Tutorial
17:12
Send ETH payments using React.js / MetaMask
15:22
Просмотров 29 тыс.
React Website: Connect to metamask wallet button
15:56