Why does Array.from accept non-iterable arraylikes?
jason.orendorff at gmail.com
Mon Jun 24 08:54:35 PDT 2013
According to , Array.from will first try treating the argument as
an iterable, then as an arraylike. This is much better than just
arraylike. The committee considered making it iterable only, but
decided against it. The rationale recorded in the notes is:
Rick, can you expand on that a bit? :-)
I propose changing it to iterable only. All builtin arraylike objects
are iterable now, including arguments, per the same discussion.
Certainly the idea is for all DOM arraylikes to be iterable. So what
is this for?
P.S. Rick: Thanks again for taking notes at the meetings. They're
indispensible. I've cloned the repo; grepping the notes has been super
More information about the es-discuss