Created
November 19, 2023 21:15
-
-
Save colinfwren/194ab23495e7296ec9ce11cb2730c964 to your computer and use it in GitHub Desktop.
Date Test Generic SwiftData Model
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import Foundation | |
import SwiftData | |
@Model | |
final class ApproachModel { | |
var title: String | |
var shownInYear: Bool = true | |
var shownInMonth: Bool = true | |
var shownInWeek: Bool = true | |
var shownInDay: Bool = true | |
// implementation specific properties | |
init(title: String, shownInYear: Bool, shownInMonth: Bool, shownInWeek: Bool, shownInDay: Bool) { | |
self.title = title | |
self.shownInYear = shownInYear | |
self.shownInMonth = shownInMonth | |
self.shownInWeek = shownInWeek | |
self.shownInDay = shownInDay | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment