SwiftUI is the latest trending way to create apps for all Apple platforms. By using SwiftUI we can create apps with more beautiful and More fast development compare with previous development. In this Ios example tutorial we will cover how to create First SwiftUI project in Xcode latest versions. Here we are using the Xcode version 13.
Let's get started
Some of Xcode shortcut keys for developers
Step 2: After installation open your Xcode from launcher
Now you will see a window which will be looks like below
There you will find various platform options like ios, macos, watchos,tvos, choose iOS —> App, Click on Next
Step 3: Configure App name and other
Follow below steps to configure app
If you want to create git repository to your project select Check box Create Git repository on my Mac —> Click on Create. Git is a distributed version-control system for tracking changes in source code during software development, read more about Git Tutorial
Step 4: After finishing you will see below window which will create your first SwiftUI project. You can find folder structure and other configuration information like bundle identifier...
Step 5: Now open ContentView.swift file which contains your view code, which is the start point for your UI. In the default application you can find simple label which will be created by using Text component in SwiftUI.
You can review your preview on the right side of the panel like below screen
Step 6: Now open your simulator and run your first SwiftUI project
Here all the SwiftUI componets and Topics
We will cover all these component examples in coming tutorials.
Spacers and Dividers
Other Component Properties
Swift Package Manager
Conclusion: In this example we covered what is SwiftUI and how to create First SwiftUI project in Xcode
Article Contributed By :