I’m attaching a UISearchController to the navigationItem.searchController property of a UITableViewController on iOS 11. This works fine: I can use the nice iOS
navigationItem.searchController
You can set the property isActive to true after adding the searchController to the navigationItem.
isActive
true
navigationItem
Just like this:
override func viewDidAppear(_ animated: Bool) { super.viewDidAppear(animated) searchController.isActive = true }