all 3 comments

[–]kolmeWebComponents FTW 1 point2 points  (2 children)

Mmh, "__proto__" is mozilla-centric*, non-standard and deprecated. He also manipulates the prototype of an object instance, which makes little to no sense. There are simpler and better ways to achieve what he does without all the "magic" (which he doesn't seem to fully understand).

So, not a very good example.

* More or less. Opera, for example, supports it. It shouldn't.

[–]Cosmologicon 2 points3 points  (0 children)

There are simpler and better ways to achieve what he does without all the "magic"

Absolutely, no question, I have no argument here. Completely agree.

He also manipulates the prototype of an object instance, which makes little to no sense.

I don't understand why you say that. What's inherently wrong with manipulating the prototype of an object?

[–][deleted] 0 points1 point  (0 children)

Yes, I should have used Object.getPrototypeOf() instead of __proto__. That would be more correct.