스플래시 페이지 추가
This commit is contained in:
21
SodaLive/Sources/Extensions/DateExtension.swift
Normal file
21
SodaLive/Sources/Extensions/DateExtension.swift
Normal file
@@ -0,0 +1,21 @@
|
||||
//
|
||||
// DateExtension.swift
|
||||
// yozm
|
||||
//
|
||||
// Created by klaus on 2022/05/27.
|
||||
//
|
||||
|
||||
import Foundation
|
||||
|
||||
extension Date {
|
||||
func convertDateFormat(dateFormat: String = "yyyy.MM.dd") -> String {
|
||||
let formatter = DateFormatter()
|
||||
formatter.dateFormat = dateFormat
|
||||
formatter.locale = Locale(identifier: "ko")
|
||||
return formatter.string(from: self)
|
||||
}
|
||||
|
||||
func currentTimeMillis() -> Int64 {
|
||||
return Int64(self.timeIntervalSince1970 * 1000)
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user