Extra functions on Arrays, Maps, etc..

John J Barton johnjbarton at johnjbarton.com
Tue Apr 10 08:53:12 PDT 2012

On Mon, Apr 9, 2012 at 9:17 PM, Andrea Giammarchi <
andrea.giammarchi at gmail.com> wrote:

> I keep finding the frame problem overrated, specially in this case where
> the case you are passing DOM nodes between frames is ... well, extremely
> edge?

The frame problem might appear overrated if you imagine that DOM nodes need
to be "passed" between frames. But accessing an iframe's DOM nodes is
trivial property lookup, theFrame.contentWindow.querySelector(...). That
simplicity plus the experience of no significant issues in operating on the
iframe content encourages this usage pattern. Mostly devs avoid instanceof,
but eventually you end up using instanceof on an array. Nothing noticeable
happens when you do, other than your app is broken. Once you track it down
you are totally convinced that the browser is busted because the instanceof
test fails. You waste a day writing a test case to prove it.

So this iframe problem is rare but hits very hard: you already have a big
investment in some code and you have to work hard to figure out what went

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.mozilla.org/pipermail/es-discuss/attachments/20120410/ab472c4d/attachment.html>

More information about the es-discuss mailing list