jweinst1
3/26/2016 - 4:34 AM

date formatting in swift

date formatting in swift

let dateFormatter = NSDateFormatter()

let currentDate = NSDate()
dateFormatter.dateStyle = NSDateFormatterStyle.FullStyle
var convertedDate = dateFormatter.stringFromDate(currentDate)
print(convertedDate)
//"Friday, March 25, 2016\n"