Update article.md
'That's funny' -> 'It's funny'
This commit is contained in:
parent
71ff8f81b0
commit
f889f3ed43
1 changed files with 1 additions and 1 deletions
|
@ -105,7 +105,7 @@ Here's the illustration of what `rabbit instanceof Animal` compares with `Animal
|
|||
|
||||
By the way, there's also a method [objA.isPrototypeOf(objB)](mdn:js/object/isPrototypeOf), that returns `true` if `objA` is somewhere in the chain of prototypes for `objB`. So the test of `obj instanceof Class` can be rephrased as `Class.prototype.isPrototypeOf(obj)`.
|
||||
|
||||
That's funny, but the `Class` constructor itself does not participate in the check! Only the chain of prototypes and `Class.prototype` matters.
|
||||
It's funny, but the `Class` constructor itself does not participate in the check! Only the chain of prototypes and `Class.prototype` matters.
|
||||
|
||||
That can lead to interesting consequences when `prototype` property is changed after the object is created.
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue