How do I make dark effect slowly change and not suddenly in my react app | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
+ 2

How do I make dark effect slowly change and not suddenly in my react app

https://covid-tracker-beta.vercel.app/

16th Nov 2020, 12:56 AM
Bhavya
Bhavya - avatar
4 Answers
+ 9
Kinda hard to help without seeing your code but perhaps this may be of help: https://medium.com/better-programming/how-to-implement-dark-mode-in-your-react-app-63c1a0c5e337 Depending on the way you implemented. In the tutorial there was usage of "transition" property achieve the effect: .night { ... background-color: black; transition: background-color 0.3s, color 0.3s; } edit: after seeing there is a link to the project GitHub page and seeing it uses MaterialUI i found this: https://next.material-ui.com/customization/transitions/
16th Nov 2020, 7:02 PM
Burey
Burey - avatar
+ 2
Dm
17th Nov 2020, 10:54 AM
Pro Coder
Pro Coder - avatar
+ 1
Please help
16th Nov 2020, 1:27 AM
Bhavya
Bhavya - avatar
+ 1
Burey thanks for the resources, I'll check them out
17th Nov 2020, 10:59 AM
Bhavya
Bhavya - avatar