Recall & Review
beginner
What is MetaMask in the context of blockchain?
MetaMask is a browser extension and mobile app that acts as a digital wallet. It allows users to manage their Ethereum accounts and interact with decentralized applications (dApps) securely.
Click to reveal answer
beginner
What is the first step to connect a MetaMask wallet to a web application?The first step is to check if MetaMask is installed by verifying if the 'ethereum' object exists in the browser's window object.
Click to reveal answer
beginner
Which method is used to request account access from MetaMask?
The method 'ethereum.request({ method: "eth_requestAccounts" })' is used to ask the user to connect their wallet and share their account address.Click to reveal answer
beginner
What should a developer do if MetaMask is not installed?
The developer should inform the user to install MetaMask and provide a link to the official MetaMask website for download.
Click to reveal answer
intermediate
Why is it important to handle errors when connecting to MetaMask?
Handling errors ensures the app can respond gracefully if the user rejects the connection request or if there are other issues, improving user experience.
Click to reveal answer
What does the 'ethereum' object in the browser window represent?
✗ Incorrect
The 'ethereum' object is injected by MetaMask and acts as a provider to interact with the Ethereum blockchain.
Which method requests the user's Ethereum accounts from MetaMask?
✗ Incorrect
The correct modern method to request account access is 'eth_requestAccounts'.
What should your app do if 'window.ethereum' is undefined?
✗ Incorrect
If 'window.ethereum' is undefined, MetaMask is not installed, so the user should be prompted to install it.
What happens if the user rejects the connection request in MetaMask?
✗ Incorrect
Rejecting the connection request causes an error that the app should catch and handle gracefully.
Which of these is a good practice when connecting MetaMask in your app?
✗ Incorrect
Good practice includes checking for MetaMask, requesting user permission, and handling any errors.
Explain the steps to connect a MetaMask wallet to a web application.
Think about detecting MetaMask, asking permission, and managing responses.
You got /4 concepts.
Why is it important to check for MetaMask installation before connecting?
Consider what happens if the wallet is missing.
You got /4 concepts.