@datawarlockยท37 charts
Tokens
The basic units of account, and is used to represent some value. Technically the first token is the network token (so ETH for mainnet), and that token does not have a smart contract. The ERC20 standard replicated most of the functionality of a network token into a smart contract standard anyone can deploy (a token with some total supply, some number of decimals of fungibility/divisibility, and can be transferred to any address). The standards below cover the main kinds of unique tokens that exist today.
Fungible Tokens:
- ERC20: The basic fungible token.
- ERC777: An ERC20 that has a set of "Operators" who can control transfers to an extent.
- ERC4626: An ERC20 where token supply is fractionalized into deposits/withdrawals
Non-Fungible Tokens:
- ERC721, ERC1155: The two main NFT standards, ERC721 introduced token ids and ERC1155 introduced "copies" of token ids. There are many variations of these like ERC721A.
- ERC3525: A "value" is tied to each token id, no dashboard
- ERC5192: Soulbound ERC721 tokens, i.e. tokens that get locked to an address (sometimes forever)
ERC Explanations (Smart Contract EIPs)
Ethereum Improvement Proposals (EIPs) are design documents to standardize some feature for the Ethereum community. Some standards like EIP1559 and Proof of Stake change the EVM network itself and are "Core" EIPs. There are also application standards such as the ERC20 token that serve as smart contract implementation references - these are categorized as "ERC".
This dashboard covers the main ERC standards, deployment trends, top example contracts, and reference dashboards.
There are four types of ERCs covered (my categorization):
- Tokens
- Token Extensions
- Accounts
- Contract Management
Credits to @andrewhong5297 for the code and explanations.
Accounts
While wallets/accounts are typically thought of as Externally Owned Accounts (EOAs) - those things you generate seed phrases for - there have been innovations to try to simplify or enhance them using smart contracts.
- ERC6551 Token Bound Accounts (Track creation and adoption here ๐): Still a draft, but allows you to use an NFT to represent a smart contract wallet. Still owned by an EOA.
- ERC2771 Gas Relayer: Allows someone to pay your gas fee for you - but the target contract must implement an ERC2771 receiver method so this is not backward compatible.
- ERC4337 Account Abstraction (See cross-chain adoption here ๐, and read about it in depth here ๐): Takes smart contract wallets further by building in ERC2771 naturally and allowing for transaction signing/verification methods outside of just EOA signing.
Token Extensions
Functionality added on top of different token standards. There is a WIDE range of extensions that have not made it into standards yet, you can check out OpenZeppelin to see some examples (Votes and Pausable being two popular ones missing in ERC standards).
- ERC20 Permit: The biggest ERC20 UX complaint has always been that approvals have to be sent before transfers, so users need to send two transactions to do almost anything with contracts (swapping, depositing, staking, etc). Permit tries to bundle it into just a signature instead. Uniswap innovated on this recently with Permit2 which is not a standard yet.
- ERC2981 NFT Royalties: There traditionally has been no way to force royalties on trades or standard for getting the royalty percentage. ERC2981 solves the latter problem, making it easy for marketplaces like Opensea to pull this value (though it isn't always enforced). ERC4901 is another standard for this that doesn't seem to have gotten any adoption.
- ERC1363 Consecutive Transfers: You can usually only transfer one token id at a time with ERC721. This makes it so you can transfer as many as you want in one call.
I was actually surprised to see how many NFT token extensions there were, and found many of the sharing/rental standards had no implementations I could detect. So they are left out from below.
Contract Management
Contracts are complex to deploy and manage, so there have been standards to help with these operational properties.
- ERC5313, ERC173 Ownership: Basic ownership and the start of roles for permissions on certain admin functions
- ERC1167, ERC1967, ERC2535 Proxies: These all have to do with proxies. A proxy contract will have it's logic stored in an implementation contract, where you can change the implementation in the future and also have many other proxy contracts reference the same implementation contract address (saving gas costs for deployment because the proxy is less code). ERC1167 focuses on the "many other proxies" concept with clones, like argent smart contract wallets. ERC1967 focuses on upgradability and is used contentiously in most DeFi protocols. ERC2535 assumes you have split logic that needs to reference multiple implementations, used first by Aavegotchi on Arbitrum.
- ERC1271 Signatures: Remember signatures used in permit? This is a standard for breaking down more complex signatures like the ones used in NFT trading for off-chain offers/listings, where you need more JSON-like structure.