Posts

Post not yet marked as solved
7 Replies
I followed your suggestion: musicAlbumPredicate = #Predicate<MusicAlbum> { $0.artistName.localizedLowercase.contains(searchQuery.localizedLowercase) } It produced the following error messages: SwiftData/DataUtilities.swift:93: Fatal error: Couldn't find \MusicAlbum.artistName.localizedLowercase on MusicAlbum with fields [("artistName", \MusicAlbum.artistName, nil, nil), ("albumName", \MusicAlbum.albumName, nil, nil), ("songName", \MusicAlbum.songName, nil, nil), ("genre", \MusicAlbum.genre, nil, nil), ("rating", \MusicAlbum.rating, nil, nil), ("releaseDate", \MusicAlbum.releaseDate, nil, nil), ("coverPhotoFullFilename", \MusicAlbum.coverPhotoFullFilename, nil, nil)]
Post not yet marked as solved
6 Replies
*** The problem in my case has been resolved *** I was declaring 'let speechSynthesizer = AVSpeechSynthesizer()' locally in my function in SwiftUI. It has been working until Xcode 14. I moved the 'let' to the top in my struct and made it a struct property. With no other code change, the problem is resolved.
Post not yet marked as solved
6 Replies
I was hoping that Xcode 14.1 beta would solve this issue reported above, but unfortunately still the same errors. I have been getting these errors since Xcode 14.0 beta 3. Text-to-Voice is a critically important feature, but has been missing in Xcode 14 and now 14.1 beta. It works perfectly under iOS 15.6 and Xcode 13.x. Why is Apple not including this feature in Xcode 14?
Post not yet marked as solved
5 Replies
All I want is a TextField to search an API. It makes an API call after each character entered returning invalid results from API unnecessarily. TextField must have a modifier to provide an option for either changing the @State var char by char or only onCommit. I can present the TextField in another view so re-rendering doesn't do anything and put the search string into a global var, but that is an ugly solution.