Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Launch Screen Added from Info.plist is not working for SwiftUI 2.0 in iOS14.0

I have added Launch Screen Image as well as background color for launch screen From info.plist which is available in SwiftUI 2.0 or iOS 14. But My Launch Image or the back ground color does not show while launching the app in simulator iphone 12 max pro.

I have checked everything in my assets file and also matched the image name and background color name that i have provided to the info.plist but nothing works.

Here is what i have done in info.plist: enter image description here

Assets name in my assets folder:

enter image description here

While running the app in simulator it does not show the black background color or the image for launch screen it just shows a white back ground for a few second then takes to the app main view.

enter image description here

like image 466
MD Sazid Hasan Dip Avatar asked Apr 03 '21 02:04

MD Sazid Hasan Dip


People also ask

How do I add launch screen to SwiftUI?

Adding a Launch Screen In SwiftUI projects, the launch screen is not generated by default. You need to add it manually in the Info. plist file. After opening the file, you should see an entry named Launch Screen.

What is launch screen in Xcode?

Every iOS app must provide a launch screen, a screen that displays while your app launches. The launch screen appears instantly when your app starts up and is quickly replaced with the app's first screen. You create a launch screen for your app in your Xcode project in one of two ways: Information property list.


1 Answers

I hit the same issue. Restarting the simulator made it start working for me.

like image 146
James Crowley Avatar answered Nov 06 '22 21:11

James Crowley