Loading video player...
In this tutorial, Aditi walks through the fundamentals of building scalable and upgradeable smart contracts using the Diamond Proxy pattern (EIP-2535) on Rootstock. You’ll learn how the Diamond Standard enables modular smart contract architecture by splitting logic into facets, allowing developers to bypass EVM contract size limits while maintaining flexibility and upgradeability. The video also introduces Rootstock’s Bitcoin-secured infrastructure and explains how it provides a secure and cost-efficient environment for deploying advanced dApps. ____________________ Useful Links - Rootstock Developer Portal - https://dev.rootstock.io/ - Rootstock Hacktivator Program - https://rootstock.io/hacktivator/ - EIP-2535 Diamond Standard Documentation - https://eips.ethereum.org/EIPS/eip-2535 - Hardhat Documentation - https://hardhat.org/docs - OpenZeppelin Contracts - https://docs.openzeppelin.com/contracts/ ______________________ Timestamps 00:00 Introduction to Rootstock and EIP-2535 02:27 Understanding the Diamond Proxy Pattern 05:04 Gas Optimization and Scalability in Diamond Proxies 08:08 Project Setup for Diamond Proxy Development 13:06 Writing Smart Contracts for Diamond Proxy 21:58 Implementing the Diamond Storage Library 26:50 Ownership Management in Diamond Contracts 30:33 Understanding Diamond Cut Functions 32:05 Implementing Function Replacement Logic 33:33 Adding and Removing Functions in Diamond Structure 36:41 Managing Function Selectors 39:31 Initializing Diamond Cut Logic 46:31 Enforcing Contract Code and Error Handling