mirror of
https://github.com/ruanyf/es6tutorial.git
synced 2025-05-24 18:32:22 +00:00
Merge branch 'gh-pages' of github.com:ruanyf/es6tutorial into gh-pages
This commit is contained in:
commit
ec830dec9e
@ -309,7 +309,7 @@ genObj.next('b')
|
|||||||
|
|
||||||
## for...of循环
|
## for...of循环
|
||||||
|
|
||||||
`for...of`循环可以自动遍历Generator函数,且此时不再需要调用`next`方法。
|
`for...of`循环可以自动遍历调用Generator函数时生成的Iterator对象,且此时不再需要调用`next`方法。
|
||||||
|
|
||||||
```javascript
|
```javascript
|
||||||
function *foo() {
|
function *foo() {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user