title: How to implement search bar in UITableViewController?
body: <p><strong>Context</strong>: I am building an app in <code>Swift</code> that mostly consists of a <code>UITableView</code>. Each cell consists of four labels, the data for each is pulled from core data. I've used <a href="https://developer.apple.com/library/content/referencelibrary/GettingStarted/DevelopiOSAppsSwift/CreateATableView.html" rel="nofollow noreferrer">apple's tutorial</a> as a basis for the tableview, and <a href="https://www.youtube.com/watch?v=qt8BNhpEAok&amp;t" rel="nofollow noreferrer">this tutorial</a> for core data handling. The final feature I'm working on is search and I'm struggling.</p>
  
  <p><strong>Problem:</strong> The problem I'm having is that most tutorials for searching tableviews seem to be structured around adding search to a tableview that is connected as an outlet within a UIViewController. I've followed the apple tutorial so my tableview is set up within UITableViewController. I'm essentially stuck on the following issue: how can I implement a search bar within UITableViewController that filters cells based on their primary label (which is pulled from core data)?</p>