Explore app playgrounds in Swift Playgrounds on iPad
In the Swift Playgrounds app , you can explore the samples in the App Gallery and Extend Your App sections of the More Playgrounds screen. Tap an app playground to open it. In any app playground, the code appears on the left, and the code results automatically appear in the App Preview on the right.
You can share your app playgrounds with friends and submit your apps to the App Store. See Share a playground.
You can also open your apps in Xcode—an app for taking your app playgrounds further. You can download Xcode free from the Mac App Store.
Walk through code in app playgrounds
You can explore SwiftUI by walking through the code in the sample app playgrounds in Swift Playgrounds. They come with built-in guides, which walk through the code and explain how it works.
On the More Playgrounds screen in the Swift Playgrounds app on your iPad, tap Get next to one of the sample app playgrounds in the App Gallery, then tap to open it.
Tap at the top right to open the guide in the sidebar on the right.
Tap Start Walkthrough (if it appears) or another button in the guide on the right.
View the assets in an app playground
An app playground can include Swift files, images, Swift packages, and other assets. The app playgrounds in the App Gallery have such assets.
To see a list of the assets in an app playground, tap at the top left to open the left sidebar. When you tap an asset to open it, it appears in a tab at the top of the coding area.
The Swift files in the sidebar (indicated by ) contain code. To see the code in a Swift file, tap it in the sidebar. You can have multiple files open at the same time and switch between open files by tapping the tabs.
You can see other assets in the app playground by tapping them in the sidebar or by tapping their tab at the top of the coding area.