_toConsumableArray throw type error for empty object. #12052
Answered
by
JLHwung
PareshRadadiya
asked this question in
Q&A
-
The |
Beta Was this translation helpful? Give feedback.
Answered by
JLHwung
Sep 11, 2020
Replies: 1 comment
-
This is expected. Including empty object, a plain object is not iterable and thus for (const v of {});
// throws {} is not iterable |
Beta Was this translation helpful? Give feedback.
0 replies
Answer selected by
PareshRadadiya
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
This is expected. Including empty object, a plain object is not iterable and thus
_toConsumableArray
will throw.