MCPcopy
hub / github.com/basarat/typescript-book / next

Method next

code/es6/iterators.ts:17–26  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

15 constructor(public name: string, public components: Component[]) {}
16
17 public next(): {done: boolean, value?: Component} {
18 if (this.pointer < this.components.length) {
19 return {
20 done: false,
21 value: this.components[this.pointer++]
22 }
23 } else return {
24 done: true
25 }
26 }
27
28}
29

Callers 6

iterators.tsFile · 0.80
iterators.jsFile · 0.80
fulfilledFunction · 0.80
asyncAwaitES6.jsFile · 0.80
fulfilledFunction · 0.80
asyncAwaitES5.jsFile · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected