How can I make it so that the cell shows the time it was created and edited?
I could not find anything about this
minutes / hours / days / weeks, etc.
Code part:
func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell {
let cell = tableView.dequeueReusableCell(withIdentifier: "cell", for: indexPath) as! CustomCell
cell.nameText?.text = myData[indexPath.row]
//
let date = Date()
let formatter = DateFormatter()
formatter.dateFormat = "MM/dd/yyyy HH:mm:ss"
let stringDate = formatter.string(from: date)
//
cell.NoneLabel?.text = stringDate
return cell
}