function* fireUp(){ yield 1; yield 2; yield 3; yield 4; yield 5; } const iterator = fireUp(); for(let i=0; i<10; i++)console.log(iterator.next());