Closed sheleoni closed 1 year ago
if the next question is the same as the previous one, users may not know they are on a new question
~probably with useEffect~ add key (from question number) to current question
Josh Comeau's Joy Of React module 5 - add CSS transition to element even if the new state has the same value as the previous state with the use of keys https://courses.joshwcomeau.com/joy-of-react/05-happy-practices/01.01-key-exercises
https://react.dev/learn/you-might-not-need-an-effect
Current issue
if the next question is the same as the previous one, users may not know they are on a new question
Implementation
~probably with useEffect~ add key (from question number) to current question
Reference
Josh Comeau's Joy Of React module 5 - add CSS transition to element even if the new state has the same value as the previous state with the use of keys https://courses.joshwcomeau.com/joy-of-react/05-happy-practices/01.01-key-exercises
Additional Reading
https://react.dev/learn/you-might-not-need-an-effect