Skip to content
  • Unlock Pro
  • Log in with GitHub
Solution
Submitted over 2 years ago

Advice Generator Solution

Kelsey Hughes•80
@kelbri10
A solution to the Advice generator app challenge
View live sitePreview (opens in new tab)View codeCode (opens in new tab)

Solution retrospective


This was a great exercise to start my morning off with. The one major issue I had initially was that the cache utilized in the API caused the function to call the same quote despite waiting the 2 seconds before hitting for a new quote. I utilized StackOverflow to look up solutions in order to resolve this issue that every time the user hits the dice they would receive a new quote. The solution I ended up using includes an object cache and sets it to no cache that way the data is constantly refreshing when the dice button is clicked.

Code
Loading...

Please log in to post a comment

Log in with GitHub

Community feedback

No feedback yet. Be the first to give feedback on Kelsey Hughes's solution.

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

Stay up to datewith new challenges, featured solutions, selected articles, and our latest news

Frontend Mentor

  • Unlock Pro
  • Contact us
  • FAQs
  • Become a partner
  • Use cases

Explore

  • Learning paths
  • Challenges
  • Solutions
  • Articles

Community

  • Discord
  • Guidelines

For companies

  • Hire developers
  • Train developers
© Frontend Mentor 2019 - 2025
  • Terms
  • Cookie Policy
  • Privacy Policy
  • License