Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

118
Views
¿Hay alguna manera de llamar a una función asíncrona desde el ámbito externo?
getPhotoStatus(); async function getPhotoStatus () { let res = await fetchPhoto('/photos/19062657811.png'); console.log(res); } async function fetchPhoto(uri) { const status = fetch(uri).then(response => response.status); return status; }

Tengo este código aquí, funciona bien pero eliminando getPhotoStatus() y esperando la función de búsqueda directamente en fetchPhoto() devuelve una Promesa, ¿hay otra forma de hacer esto en lugar de hacer funciones dobles básicamente para obtener el valor de una Promesa directamente de el alcance exterior?

about 4 years ago · Juan Pablo Isaza
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!