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 Solution

#node
Louie 170

@PaletteJack

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


Thanks for checking out my solution!

It took me a while to get it deployed to heroku.. finally got it figured out though!

I really just used node to create an initial quote when the app is loaded. After that it's all client side. Works okay, my first time using fetch().

Community feedback

Shiva 670

@shivaprakash-sudo

Posted

Hello PaletteJack,

The site looks good and is responsive, but it doesn't work in Firefox after the initial advice is loaded. This is because of the Advice API caching the data when we fetch it, this can be avoided by putting { cache: "no-cache" } as a second argument inside the fetch method.

Regarding the initial advice, you don't need to use back-end for that, you can do it directly on client side using the same getAdvice method on window.onload function.

You did good for your first time, keep up the spirit and good luck on your next projects.

Marked as helpful

1

Louie 170

@PaletteJack

Posted

@shivaprakash-sudo ooooh I didn't know that! good to know, I'll update the code and test that it's working on firefox. Thank you!

1
Shiva 670

@shivaprakash-sudo

Posted

@PaletteJack

You're welcome!

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