Читать книгу SwiftUI For Dummies - Wei-Meng Lee - Страница 13

Hello, SwiftUI

Оглавление

After you’ve installed Xcode, you’ll probably be very eager to try out SwiftUI. So, let’s take a dive into SwiftUI and see how it works! Follow these steps:

1 Launch Xcode.

2 Click Create a new Xcode project (see Figure 1-4).

3 Select Single View App and click Next (see Figure 1-5).

4 In the Product Name field, enter HelloSwiftUI (see Figure 1-6).

5 In the Organization Name field, enter your name.

6 In the Organization Identifier field, enter a unique identifier, such as the reverse domain name of your company.

7 From the User Interface drop-down list, select SwiftUI.

8 Click Next and save the project to a location on your Mac.You should see the project created for you (see Figure 1-7). The ContentView.swift file contains the UI for your application's main screen.


FIGURE 1-4: Launching Xcode.


FIGURE 1-5: Selecting the Single View App project type.


FIGURE 1-6: Naming the project.


FIGURE 1-7: Viewing the project that you’ve created.

SwiftUI For Dummies

Подняться наверх