Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
686 views
in Technique[技术] by (71.8m points)

ios - No main.storyboard or ViewController.swift upon initialization of new project in Xcode?

I just got Xcode and I am trying to follow an online tutorial but in every single tutorial, when a new project is made (a single activity) app, the project comes with 2 files that I simply don't have by default! I can't figure out how to make a main.storyboard or ViewController.swift file by default upon creating a project.

The only files I have are AppDelegate.swift, SceneDelegate.swift, and ContentView.swift. I also have Assets.xcassets, LaunchScreen.storyboard, Info.plist, Preview Content directory, and Products directory.

Is this part of a new update or something? Or is there some way I can get those 2 files to create upon initialization?

I tried reinstalling, and have made multiple new projects - each time they lack those 2 crucial files, so any help would be appreciated.

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Reply

0 votes
by (71.8m points)

In the latest Xcode, select Storyboard from the User Interface dropdown, enter image description here

Older Xcode

Unselect Use SwiftUI at the following step,

enter image description here


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
OGeek|极客中国-欢迎来到极客的世界,一个免费开放的程序员编程交流平台!开放,进步,分享!让技术改变生活,让极客改变未来! Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...