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

Advice Generator APP - SASS - API`s - Animation Features

accessibility, sass/scss, fetch
Luis Pellizzon•50
@lhpellizzon
A solution to the Advice generator app challenge
View live sitePreview (opens in new tab)View codeCode (opens in new tab)

Solution retrospective


Good morning everyone, I took a step forward and decided to take this project to practice my Javascript back again. Fetching the data from the API was not the difficult part for me, and I use a new feature called Destructuring syntax from ES6 to manipulate the data easier. The hardest part, at least for me, was trying to implement some animation features whenever a client fetch a new quote data and the rotate (roll) animation when the button is activated. So, after going reading some articles I came up with an idea:

  • When the button is clicked, it adds animation a fade-in class on the quote tage and add the dice image, and with a setTimeOut, I could remove after the animation was finished.

The only problem is, if we click really fast on the button, it takes a while to fetch a new data. Is it normal or it is just a bug?

Please, I would really appreciate feedbacks. 🫶🏻

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 Luis Pellizzon'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