Skip to content

Latest commit

 

History

History

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 

Day 59: Project 12: Core Data (Part Three)

Follow along at https://www.hackingwithswift.com/100/swiftui/59.


📒 Field Notes

This day covers Part Three of Project 12: Core Data in the 100 Days of SwiftUI Challenge. (Project 12 files can be found in the directory for Part One.)

In addition to recapping the material covered during the project's other days, Day 59 focuses on extending the project according to a set of challenges.


🥅 Challenges

From the description:

All three of these tasks require you to modify the FilteredList view we made.

Challenge 1

Make the FilteredList view accept an array of NSSortDescriptor objects to get used in its fetch request.

Challenge 2

Make the FilteredList view accept a string parameter that controls which predicate is applied. You can use Swift’s string interpolation to place this in the predicate.

Challenge 3

Modify the predicate string parameter to be an enum such as .beginsWith, then make that enum get resolved to a string inside the initializer.