I have Bar Button Item with Title "Edit" in UITableViewController.
@IBOutlet weak var button: UIBarButtonItem!
@IBAction func pushEdit(_ sender: Any) {
tableView.setEditing(!tableView.isEditing, animated: true)
}
I need to change TextLabel from "Edit" to "Done" when the user clicked on "Edit" button.
It seems that setTitle(_:for:) doesn't work.
What is the way to change Title?