Open
Description
When the user is in light mode, refreshing the page showes temporarily the dark mode, and the chosen mode is applied only after the page has been fully loaded.
From kazk:
Codewars doesn't refresh the page most of the time while using, so it shouldn't be a huge problem. To fix it completely, I think I need to persist the user's option in the database and render HTML with the theme class name.
Or maybe the theme detection can be separated and moved earlier, so it switches the theme before most of the page is loaded (I think the docs does this). If the latter works well, I can fix it easily.