Why doesn't my iOS app disable dark mode?

前端 未结 3 1885
礼貌的吻别
礼貌的吻别 2021-02-14 09:04

So ... I\'ve tried to set my app to disable iOS 13 dark mode by forcing light mode according apple documentation, in the emulator all attempts work fine, but when I try on the r

3条回答
  •  别跟我提以往
    2021-02-14 09:45

    if #available(iOS 13, *) {
        window.overrideUserInterfaceStyle = .light
    }
    

    Should work. Call it in your AppDelegate's didFinishLaunchingWithOptions.

提交回复
热议问题