[ad_1]
I am making an attempt to transform a date to a string utilizing iOS 15 type formatter like this:
let date = Date()
let formattedDate = date.formatted(
.dateTime
.month(.twoDigits)
.day()
.yr()
)
The Date (as printed within the console) is
"2022-06-19 16:42:56 +0000"
How can I construct the next string:
"2022 ** 06 ** 19"
out of this date object, utilizing the brand new iOS 15 date formatter?
[ad_2]
Source link