I\'m trying to implement a simple search bar using Apple\'s latest UISearchController. However I can\'t seem to get it to work correctly if I use the search bar
This appears to be a known defect. There are several radr entries such as http://www.openradar.me/20702394 that refer to similar issues and a workaround by using sizeToFit()
The workaround they suggest works, but only when it was applied within viewDidLayoutSubviews. i.e. after all of the views were laid out.
override func viewDidLayoutSubviews() {
self.searchController.searchBar.sizeToFit()
}