File tree Expand file tree Collapse file tree 1 file changed +12
-3
lines changed
Expand file tree Collapse file tree 1 file changed +12
-3
lines changed Original file line number Diff line number Diff line change @@ -312,7 +312,7 @@ export const Iterator = {
312312 } ,
313313
314314 /**
315- * converts iterator into an array.
315+ * collects the iterator into an array.
316316 *
317317 * @return {Array }
318318 */
@@ -321,7 +321,7 @@ export const Iterator = {
321321 } ,
322322
323323 /**
324- * converts iterator into a set.
324+ * collects the iterator into a set.
325325 *
326326 * @return {Set }
327327 */
@@ -330,12 +330,21 @@ export const Iterator = {
330330 } ,
331331
332332 /**
333- * converts iterator into a map.
333+ * collects the iterator into a map.
334334 *
335335 * @return {Map }
336336 */
337337 intoMap ( ) {
338338 return new Map ( this . ref ) ;
339+ } ,
340+
341+ /**
342+ * collects the iterator into an object.
343+ *
344+ * @return {object }
345+ */
346+ intoObject ( ) {
347+ return Object . fromEntries ( this . ref ) ;
339348 }
340349} ;
341350
You can’t perform that action at this time.
0 commit comments