Sesame-iOS/Sesame/SesameApp.swift

21 lines
381 B
Swift
Raw Normal View History

2022-01-29 18:59:42 +01:00
import SwiftUI
2023-12-12 17:33:42 +01:00
import SwiftData
2022-01-29 18:59:42 +01:00
@main
struct SesameApp: App {
2023-12-12 17:33:42 +01:00
@State
var modelContainer: ModelContainer
init() {
2023-12-27 21:57:17 +01:00
self.modelContainer = SesameApp.loadModelContainer()
2023-12-12 17:33:42 +01:00
}
2022-01-29 18:59:42 +01:00
var body: some Scene {
WindowGroup {
2023-12-12 17:33:42 +01:00
ContentView(modelContext: modelContainer.mainContext)
2022-01-29 18:59:42 +01:00
}
2023-12-12 17:33:42 +01:00
.modelContainer(modelContainer)
2022-01-29 18:59:42 +01:00
}
}