1.選中項目-->Generral-->Deployment-->Main Interface 設為空

image.png
2.刪除Main.storyboard 文件--

image.png
3.刪除info.plist下的Main.storyboard 描述(注意文件位置)

image.png
4.注意設置根視圖的代碼移動到了SceneDelegate.swift中了
func scene(_ scene: UIScene, willConnectTo session: UISceneSession, options connectionOptions: UIScene.ConnectionOptions) {
guard let windowScene = (scene as? UIWindowScene) else { return }
window = UIWindow(frame: windowScene.coordinateSpace.bounds)
window?.windowScene = windowScene
window?.backgroundColor = UIColor.white
window?.makeKeyAndVisible()
window?.rootViewController = TabBarViewController()
}