title: SwiftUI Bind to core data object inside foreach
body: <p>I am not able to bind the bookName from my Core Data object to a TextField inside a ForEach loop. How can I get this binding to work? I want the bookName value to be saved to Core Data when it changes.</p>
  <p>I am receiving an error that says: Cannot find $book in scope.</p>
  <pre><code>extension Book: Identifiable {
                  @nonobjc public class func fetchRequest() -&gt; NSFetchRequest&lt;Book&gt; {
                      return NSFetchRequest&lt;Book&gt;(entityName: &quot;Book&quot;)
                  }
                  
                  @NSManaged public var id: UUID?
                  @NSManaged public var bookName: String?
                  
                  var wrappedBookName: String {
                      bookName ?? &quot;&quot;
                  }
             }    
              
      struct BookListView: View {
              @FetchRequest(entity: Book.entity(), sortDescriptors: [NSSortDescriptor(keyPath: \Book.rankNumber, ascending: false)]) var books: FetchedResults&lt;Book&gt;
                  
                   var body: some View {
                      ForEach(books) { book in
                         TextField(&quot;Book Name&quot;, text: $book.bookName)  //Error: cannot find $book in scope
                      }
                   }
      }
  </code></pre>