Ethereum developers have built a large ecosystem around the ERC20 token standard, but some limitations are starting to emerge. One of these limitations is that users continuously lose tokens by accidentally transferring them to contract addresses.
ERC223 is a proposal to add a fail-safe to token contracts to ensure that a contract is expecting token transfers before sending tokens to it. It's an interesting idea to help prevent new users from getting #rekt.
I take a look at the proposal in the first part of an ongoing series breaking down Ethereum Improvement Proposals.
looks like this. This contract creates an imaginary coin called DecypherCoin and the tokens live inside it. When a user wants to send tokens to another account they call the transfer function which will update the balances in the contract. When the user wants to send tokens to a contract they use a different workflow, first they approve the contract to spend tokens on their behalf which updates the allowances doesnât update the balances, and then the contract can call the transferFrom function and update the balance of the token contract.