Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found

Submitted

Advice Generator App

@andykallian

Desktop design screenshot for the Advice generator app coding challenge

This is a solution for...

  • HTML
  • CSS
  • JS
  • API
2junior
View challenge

Design comparison


SolutionDesign

Solution retrospective


Hello!

I've enjoyed using API in a project! I'm studying exactly how to make requests in APIs and projects like these are such a excelent way to practice!

Greetings!

Community feedback

David 8,000

@DavidMorgade

Posted

Buenas Anderson enorabuena por completar el challenge!

Yo creo que a tu código lo único que le faltaría es hacer la petición de manera asyncrona, es decir, en Javascript todo ocurre de manera secuencial, pero las peticiones http necesitan ser ejecutadas de manera asyncrona y esperar un resultado, una vez que este el resultado se ejecuta el resto del código.

Esto lo puedes conseguir de manera sencilla usando async await, te recomiendo este articulo: https://developer.mozilla.org/es/docs/Web/JavaScript/Reference/Statements/async_function , que está muy bien, sobre como funcionan las funciones asyncronas.

Espero que mi feedback te sea de ayuda.

0

@andykallian

Posted

@DavidMorgade i'm grateful for your feedback! in fact, in still learning how to work with API and surely your coment will help me!

thanks!

0

Please log in to post a comment

Log in with GitHub
Discord logo

Join our Discord community

Join thousands of Frontend Mentor community members taking the challenges, sharing resources, helping each other, and chatting about all things front-end!

Join our Discord