Set background color before app is displayed?

On my current app (Android based), I have it so the user can select to enable/disable dark mode. Whatever the user selects is saved to a settings file and is re-set anytime the app is run. The problem is, if dark mode is selected, the app “flashes” a white screen first before the dark mode is set. Is there a way to set the dark mode them before anything is displayed so as to avoid the white screen flash?

Add a hover layer that will mask the transition

What exactly is a hover layer?