summaryrefslogtreecommitdiff
path: root/ADSBDecoder/ADSBDecoderApp.swift
blob: 491dbc52b72261da40b8138c977f53db81c20da4 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
//
//  ADSBDecoderApp.swift
//  ADSBDecoder
//
//  Created by Jacky Jack on 26/09/2026.
//

import SwiftUI
import SwiftData

@main
struct ADSBDecoderApp: App {
    var sharedModelContainer: ModelContainer = {
        let schema = Schema([
            Item.self,
        ])
        let modelConfiguration = ModelConfiguration(schema: schema, isStoredInMemoryOnly: false)

        do {
            return try ModelContainer(for: schema, configurations: [modelConfiguration])
        } catch {
            fatalError("Could not create ModelContainer: \(error)")
        }
    }()

    var body: some Scene {
        WindowGroup {
            ContentView()
        }
        .modelContainer(sharedModelContainer)
    }
}