Calling async function from sync: async function wait() { await new Promise(resolve => setTimeout(resolve, 1000)); return 10; } function f()
A collection of my tech notes
Calling async function from sync: async function wait() { await new Promise(resolve => setTimeout(resolve, 1000)); return 10; } function f()