26.4 Using Scene Storage
Edit the SceneStorageView.swift file and modify it so that it reads as follows:
import SwiftUI
struct SceneStorageView: View {
@State private var editorText: String = ""
var body: some View {
TextEditor(text: $editorText)
.padding(30)
.font(.largeTitle)
}
}
This declaration makes use of the TextEditor view. This is a view designed to allow multiline text to be displayed and edited within a SwiftUI app and includes scrolling when the displayed text extends beyond the viewable area. The TextEditor view is passed a binding to a state property into which any typed text will be stored (note that we...