Fix typos

This commit is contained in:
Alexey Pyltsyn 2019-05-01 16:51:27 +03:00
parent ca92aed539
commit feebafcc9e
5 changed files with 5 additions and 5 deletions

View file

@ -171,7 +171,7 @@ class CoffeeMachine {
new CoffeeMachine().setWaterAmount(100);
```
That looks a bit longer, but functions are more flexible. They can accept multiple arguments (even if we don't need them right now). So, for the future, just in case we need to refactor something, functions are a safer choise.
That looks a bit longer, but functions are more flexible. They can accept multiple arguments (even if we don't need them right now). So, for the future, just in case we need to refactor something, functions are a safer choice.
Surely, there's a tradeoff. On the other hand, get/set syntax is shorter, so ultimately there's no strict rule, it's up to you to decide.
````

View file

@ -182,7 +182,7 @@ alert( {}.toString.call(user) ); // [object User]
For most environment-specific objects, there is such a property. Here are few browser specific examples:
```js run
// toStringTag for the envinronment-specific object and class:
// toStringTag for the environment-specific object and class:
alert( window[Symbol.toStringTag]); // window
alert( XMLHttpRequest.prototype[Symbol.toStringTag] ); // XMLHttpRequest