Web3.js, Ethers.js and Ethereum APIs Flashcards
6 cards from real Ethereum Developer practice questions. Tap to flip, then mark Knew It or Still Learning โ missed cards come back until you master them.
Read the first 6 Web3.js, Ethers.js and Ethereum APIs flashcards as text
What is the primary purpose of the ethers.js library in Ethereum development?
Answer: To interact with the Ethereum blockchain from JavaScript/TypeScript applications
Ethers.js is a lightweight JavaScript library for connecting to Ethereum nodes, signing transactions, and interacting with smart contracts.
What is a Provider in the context of ethers.js?
Answer: A read-only connection to an Ethereum node for querying blockchain data
A Provider in ethers.js represents a connection to the Ethereum network, enabling read-only queries like fetching balances and blocks.
What is a Signer in ethers.js?
Answer: An abstraction that holds a private key and can sign and send transactions
A Signer in ethers.js is an abstraction over a private key, enabling signing messages and sending transactions to the Ethereum network.
What does ABI stand for in Ethereum development?
Answer: Application Binary Interface
The ABI (Application Binary Interface) defines how to encode and decode function calls and return values when interacting with a smart contract.
Which JSON-RPC method is used to get the ETH balance of an address on Ethereum?
Answer: eth_getBalance
`eth_getBalance` returns the Wei balance of a given address at a specified block number.
What is MetaMask's primary role in a browser-based dApp?
Answer: An injected wallet that provides a Web3 provider and Signer to the dApp
MetaMask injects a `window.ethereum` provider object into the browser, enabling dApps to request account access and sign transactions.