Ethereum Virtual Machine
The Ethereum Virtual Machine (EVM) functions as a world computer that powers decentralized applications (dApps) running on the Ethereum blockchain.
Decentralised Apps enable people to make transactions via Wallets to a decentralized blockchain database through a Smart Contract Interface or ABI, Application Binary Interface. In the context of computer science this is an interface between two program modules, most often between operating systems and user programs.
Development
Data Access
Smart Contracts are only as smart as the data they can process allows them to be.
The journey from Web2 to Web3 with Scaffold Eth.
Related
Concepts
Smart Contracts control the flow of information and value on a blockchain through one way decisions based on immutable logic acting on data compiled and stored to ensure integrity.
Hybrid Smart contracts are key to unlocking real value for society. See Engineering Smart Contracts to understand how to code smart contracts.
Foundations
Every smart contract execution triggers a change to the EVM's state, aka a state transition.
- Contract bytecode (compiled from the source code) is loaded from the EVM's storage and executed by peer-to-peer nodes on the EVM. Nodes use the same transaction inputs, which guarantees that each node arrives at the same result (or else they cannot reach consensus).
- EVM Opcodes (contained in the bytecode) interact with different parts of the EVM’s state (memory, storage, and stack). Opcodes perform read-write operations—reading (getting) values from state storage and writing (sending) new values to the EVM’s storage.
- EVM opcodes perform computation on the values obtained from state storage before returning the new values. This update results in the EVM transitioning to a new state (transactions are called “state transitions” for this reason). This new state is replicated by other nodes and remains until another transaction is executed.
Principles to have mastered:
- Best Possible Tooling
- Solidity Prerequisites
- Fuzzing and Invariants
- Installing Libraries
- ERC20 Tokens
- ERC721 Tokens
- Advanced Solidity
- Storage Patterns
- Fallback and Receive
- ABI Encode
- Encoding Functions
- Upgradeable Contracts
- Self Destruct
- Fork Tests
Gas Costs
Scripting
Learn the fundamentals of interacting with Smart Contracts by scripting a CLI.
Production CLIs