initial pre-viable version of watch app
This commit is contained in:
14
Worksouts Watch App/Utils/Date+formatDateET.swift
Normal file
14
Worksouts Watch App/Utils/Date+formatDateET.swift
Normal file
@ -0,0 +1,14 @@
|
||||
import Foundation
|
||||
|
||||
extension Date {
|
||||
func formatDateET(format: String = "MMMM, d yyyy @ h:mm a z") -> String {
|
||||
let formatter = DateFormatter()
|
||||
formatter.timeZone = TimeZone(identifier: "America/New_York")
|
||||
formatter.dateFormat = format
|
||||
return formatter.string(from: self)
|
||||
}
|
||||
|
||||
static var ISO8601: String {
|
||||
"yyyy-MM-dd'T'HH:mm:ssZ"
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user