Is there a straightfoward way to create toggleable themes in an electron and react app?
Use Bootstrap, Semantic UI, Foundation or any other front-end framework, there are plenty of themes available for either. If you’re looking for an example – some years ago (aka I’d do it differently today) I used Bootstrap with a theme selector on this page.
No, I’m referring to the ability to create a set of css rules and toggle on command.
For example, think of a day/night theme.
My first thought would be to just have a state in every component indicating the current theme, and then toggling that state when needed. This of course seems overly complex having to implement it into every component separately.