Update README.md

This commit is contained in:
Artem Zakharchenko 2017-06-30 13:15:24 +02:00 committed by GitHub
parent 3df5290e3e
commit a1b30f6cb2

View File

@ -102,13 +102,13 @@ Set something back to its initial value.
```js
const initialFruits = 5;
const fruits = initialFruits;
setFruits(10); // fruits = 10
setFruits(10); // fruits === 10
function resetFruits() {
fruits = initialFruits;
}
resetFruits(); // fruits = 5
resetFruits(); // fruits === 5
```
#### `compose`
Create new data from the existing one. Probably, applicable mostly to strings.