Random Quote Generator React - Feedback

random quote machine using react, please check it once and give feedback


Looks fine. The images don’t reload with every quote, nor every 2 quotes, as I initially thought. Reading the code, I see that this is the problem with randomness: clumping. You could check to see if the two images are the same and pull a new one. It’s a matter of choice, but it would provide more consistent behavior. Good clean code, consistent color design, and function.

1 Like

thank you for your feedback, yes sometimes images are not loading I will try to work on it

I can think of two reasons they might not load:

  1. it may be an API request limit
  2. The clumping of randomness: A truly random process will have adjacent repeating values.