Mercurial > public > lazybear
diff LazyBearWatchOS Extension/LazyBearApp.swift @ 452:bb69f9d1d20f
Implement HomeView in WatchOS
author | Dennis Concepción Martín <dennisconcepcionmartin@gmail.com> |
---|---|
date | Sat, 26 Jun 2021 18:45:31 +0200 |
parents | e4ca9898b79b |
children |
line wrap: on
line diff
--- a/LazyBearWatchOS Extension/LazyBearApp.swift Sat Jun 26 17:04:29 2021 +0200 +++ b/LazyBearWatchOS Extension/LazyBearApp.swift Sat Jun 26 18:45:31 2021 +0200 @@ -6,14 +6,16 @@ // import SwiftUI +import CoreData @main struct LazyBearApp: App { + let persistenceController = PersistenceController.shared // Core Data init + @SceneBuilder var body: some Scene { WindowGroup { - NavigationView { - ContentView() - } + ContentView() + .environment(\.managedObjectContext, persistenceController.container.viewContext) } WKNotificationScene(controller: NotificationController.self, category: "myCategory")