var projectedValue : ObservedObject <ObjectType >.Wrapper
A projection of the state object that creates bindings to its properties.
Availability 有効性
Technology
var wrappedValue: ObjectType { get }
The wrapped value property provides primary access to the value’s data. However, you don’t access wrapped
directly.
しかしながら、あなたはwrapped
に直接にアクセスしません。
Instead, use the property variable created with the @State
attribute:
var contact = Contact()
var body: some View {
Text(contact.name) // Accesses contact's wrapped value.
}
When you change a property of the wrapped value, you can access the new value immediately. However, SwiftUI updates views displaying the value asynchronously, so the user interface might not update immediately.
var projectedValue : ObservedObject <ObjectType >.Wrapper