apply(snapshot:previous:)
Applies loaded content to the document model.
Declaration
@MainActor func apply(snapshot: sending Self.Reader.Snapshot, previous: sending Self.Reader.Snapshot?) async throwsParameters
- snapshot:
The snapshot loaded from disk.
- previous:
The previously loaded snapshot. Compare to
snapshotto update only what changed.
Discussion
SwiftUI calls this method on the main actor after reading completes.