Skip to content

Commit 577f47e

Browse files
authored
Update README.md
1 parent ef257b2 commit 577f47e

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

erc777/README.md

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,17 +2,20 @@
22

33
The [ERC777 Token Standard](https://eips.ethereum.org/EIPS/eip-777) improves upon the popular [ERC20](https://contracts.vyperhub.io/contracts/erc20) standard.
44

5-
Its most defining feature is the use of the new [ERC1820](http://eips.ethereum.org/EIPS/eip-1820) interface standard which it uses in such a way, that each time tokens are sent two things happen:
6-
1. The ERC777 contract It checks whether the sender of the transaction is a contract and whether that contract implements a `tokensToSend(_operator, _from, _to, _amount, _data, _operatorData)` function.
5+
Its most defining feature is the use of the new [ERC1820](http://eips.ethereum.org/EIPS/eip-1820) interface standard which it uses in such a way, that each time tokens are sent the ERC777 contract does two things:
6+
1. It checks whether the sender of the transaction is a contract and whether that contract implements a `tokensToSend(_operator, _from, _to, _amount, _data, _operatorData)` function.
77
2. It checks whether the receiver of the transaction is a contract and whether that contract implements a `tokensToSend(_operator, _from, _to, _amount, _data, _operatorData)` function.
88

99
If the functions exist, then the code inside of both functions is executed.
1010
The exciting part is, that there are no restrictions on what the code inside of the two functions looks like or what it does.
1111

1212
## Tests
13+
1314
### Run local tests
15+
1416
```bash
1517
$ truffle test --network ganache
1618
```
1719
### More tests
20+
1821
Further tests for this implementation may be found [here](https://github.com/0xjac/ERC777/tree/master/test).

0 commit comments

Comments
 (0)