Date
public extension Date
-
Checks if the date corresponds to today, regardless of the time.
Declaration
Swift
var isToday: Bool { get }
-
Checks if the date is from the past.
Declaration
Swift
var isDayFromPast: Bool { get }
-
Checks if the date is from the future.
Declaration
Swift
var isDayFromFuture: Bool { get }
-
Returns the date as a day number (ie: 28).
Declaration
Swift
var dayNumber: Int { get }
-
Returns the short (3 letters) or full version name of the month from a given date.
Declaration
Swift
static func monthName( date: Date, returnShortVersion: Bool, locale: Locale = Locale(identifier: "en_US_POSIX") ) -> String