of and from on collection constructors S1
Proposal details
- Stage: Stage 1
- Status: Active
- ECMAScript edition: —
- Synchronized: Aug 28, 2026
- 中文译文 · Source repository
Proposal overview
This proposal aims to add static of and from methods to collection constructors (like Set and Map). It is motivated by Brendan Eich's tweet about functionality parity with arrays.
Note
The README below comes from the upstream repository and may contain outdated stage or status metadata. Use the proposal details above as the current source of truth.
of and from on collection constructors
Champions
- Kevin Gibbons
- Allen Wirfs-Brock
- Leo Balter
Status
This proposal is currently stage 1 of the TC39 process.
Motivation
https://twitter.com/BrendanEich/status/771009446298329088
Questions
https://github.com/tc39/proposal-setmap-offrom/issues
Polyfill
A polyfill is available in the core-js library. You can find it in the ECMAScript proposals section.