Me está costando entender async/await. ¿Cómo puedo hacer que la función test() espere para ejecutar el resto del código hasta que finalice la función helper()?
¡Gracias!
async function test() { await helper(); console.log("world"); } function helper() { setTimeout(() => { console.log("hello"); }, 3000); }