1
0
mirror of https://github.com/ruanyf/es6tutorial.git synced 2025-05-28 21:32:20 +00:00

docs(set-map): edit Map

This commit is contained in:
ruanyf 2017-07-02 21:34:55 +08:00
parent b9bd59dbe2
commit b9f14136be

View File

@ -467,7 +467,7 @@ items.forEach(
); );
``` ```
事实上,不仅仅是数组,任何具有 Iterator 接口的数据结构详见《Iterator》一章都可以当作`Map`构造函数的参数。这就是说,`Set``Map`都可以用来生成新的 Map。 事实上,不仅仅是数组,任何具有 Iterator 接口、且每个成员都是一个双元素的数组的数据结构详见《Iterator》一章都可以当作`Map`构造函数的参数。这就是说,`Set``Map`都可以用来生成新的 Map。
```javascript ```javascript
const set = new Set([ const set = new Set([