String match ignoring case in a Predicate
Swift Forums
String match ignoring case in a Predicate
Hi, Overview I am trying to do a string match ignoring case inside a predicate. "slow car" needs to be returned when I search for "Slow Car" Problem I have tried to use regex but wholeMatch(of: regex) is not allowed in a Predicate Question How do I search for a string ignoring a case inside a predicate? My attempt import Foundation print("Hello, World!") struct Car { let title: String let price: Int } let filterText = "Slow CAr" let regex = Regex<Any>(verbatim: filterText) ...
0 comments
No comments yet.