简体   繁体   English

我的 React Native App 默认以暗模式启动

[英]My React Native App Had started in dark mode by default

When I created a new fresh React Native App, it started with dark mode.当我创建一个新的 React Native 应用程序时,它以暗模式启动。 Previously my react native app would start with light/white background.以前我的 react native 应用程序会从浅色/白色背景开始。 I don't know how to disable the mode.我不知道如何禁用该模式。 Please help me to disable the dark mode.请帮我禁用暗模式。

The latest React Native CLI app template uses the Theme.AppCompat.DayNight.NoActionBar Android theme (set in the AndroidManifest.xml and styles.xml), which adds some automatic dark mode behavior based on a number of conditions.最新的 React Native CLI 应用程序模板使用Theme.AppCompat.DayNight.NoActionBar Android 主题(在 AndroidManifest.xml 和 ZBC4150D023D32551236DB671D61ACF 中设置,添加了一些基于 xml 的自动暗模式)。 The Android dev documentation is a good place to start to learn about this. Android 开发文档是开始了解这一点的好地方。 You can also change the theme of course if you want different behavior.当然,如果您想要不同的行为,您也可以更改主题。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM