Merge pull request #1243 from smkoyan/patch-3

Update article.md
This commit is contained in:
Ilya Kantor 2019-08-19 11:40:27 +03:00 committed by GitHub
commit 6cad8d5d23
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -99,7 +99,7 @@ It triggers when a property is read, with following arguments:
Let's use `get` to implement default values for an object.
We'll make a numeric array that returns return `0` for non-existant values.
We'll make a numeric array that returns `0` for non-existant values.
Usually when one tries to get a non-existing array item, they get `undefined`, but we'll wrap a regular array into proxy that traps reading and returns `0` if there's no such property: