JSFiddle - React, Tailwind, and code Playground

by Hugo Carneiro

JavaScript

function* as( limit = Infinity ) 
{
   let a = 0, b = 1;
   while( a < limit ) 
   {
      yield a;
      [a, b] = [b, a + b];
   }
}
var pp=3
let iterator = as( 10 );
for(var prop of iterator){
   pp=pp+23
}
var f = (x)=>10+x 
console.log(f(10) + pp)