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 (using flexbox, vanilla JS, API)

@jesuisbienbien

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


This is my first project working with API.

I notice that if I click on the button twice in a row, it will not generate a new advice as I expected it. If I click again, then it works. Any suggestions on how to fix that?

Any other feedbacks are welcome as well :)

Community feedback

Otávio 230

@Otavio-Cipriano

Posted

Hi there good job completing this challenge

So that's not an issue in your code. If you request too fast to this API, it is going to return the same response, there's a note about this in the API documentation. They cache your request for 2 seconds, so any repeat-request within 2 seconds will return the same piece of advice

I hope this helps

Cheers!

Happy coding 👍

Marked as helpful

0

@jesuisbienbien

Posted

@Otavio-Cipriano That's great! Thank you for your help.

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