Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

react native force light mode in android app

when I run my react native app in the emulator (pixel android 10), I noticed that the app change the white background to black when the phone set to dark mode. this made hard to read the black text or anything else. is there a way that forces the app to run in light theme despite the OS in dark or light mode

"react-native-appearance": "^0.3.2",
like image 659
Mohammad Avatar asked Jan 26 '20 15:01

Mohammad


1 Answers

try this Appearance.set({ colorScheme: 'light' });

like image 89
Ashish Singh Rawat Avatar answered Sep 29 '22 13:09

Ashish Singh Rawat