← Back to release summary

JS iterators (i.e. the for-of feature) (ES6)

Category
JavaScript
Type
New or changed feature
Status
Enabled by default (Chrome 38)
Intent stage
None

Summary

Iterates over iterable objects (including arrays, array-like objects, iterators and generators), invoking a custom iteration hook with statements to be executed for the value of each distinct property.

Standards & signals

Docs: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Statements/for...of http://updates.html5rocks.com/2014/08/Collecting-and-Iterating-the-ES6-Way

Samples: https://github.com/GoogleChrome/samples/tree/gh-pages/collections-iterators-es6

View on chromestatus.com