[Pas2js] JS Sync/Async Limitations

warleyalex warleyalex at yahoo.com.br
Thu Feb 21 15:34:45 CET 2019


I don't know you, it would be really cool to have await keyword native in
pas2js.
the "async" keyword to allow us to program using asynchronous requests in a
"synchronous" manner.

in modern JS:

async function r() {
  var r2 = await fetch('https://jsonplaceholder.typicode.com/posts/1');
  var j = await r2.json();
  console.log(j);
};
r();




--
Sent from: http://pas2js.38893.n8.nabble.com/


More information about the Pas2js mailing list