I wanted to create a grid of cells with no spaces or smaller space just like the Photos app, is it possible with SwiftUI 2 LazyVGrid? I've tried it but there is always this space in-between columns.
In the documentation, the spacing parameter is described as:
spacing
The spacing beween the grid and the next item in its parent view. https://developer.apple.com/documentation/swiftui/lazyvgrid/init(columns:alignment:spacing:pinnedviews:content:)
Which doesn't make much sense, can't you just use padding for that? Also, when I tried increasing the spacing, it seems to be actually impacting the space in-between rows of cells, which is even more unexpected.
Post
Replies
Boosts
Views
Activity
I'm following the video tutorial below, using the exact examples, but was not able to semantically match the results:
https://developer.apple.com/videos/play/wwdc2024/10131
https://developer.apple.com/documentation/corespotlight/building-a-search-interface-for-your-app
In iOS 18 and macOS 15 and later, Spotlight also supports semantic searches of your content, in addition to lexical matching of a search term.
I'm on macOS 15.1, so I'd expect it should work now? Or is this depend on Apple Intelligence for some reason?
Specifically I've indexed the following:
Keyword: "windsurfing carmel"
Literal match:
the best windsurfing carmel county
windsurfing lessons
Semantic match:
sailboarding lessons
the best windsurfing carmel county
windsurfing lessons
Expected: find semantic match.
Actual: only literal match were returned.
Because CSUserQuery.prepare is only supported by macOS 15, my switch from CSSearchQuery makes no sense without the semantic search benefits.
Did I miss something? I also added the corespotlight delegate extension as directed but was not able to hit the breakpoint as per the video. I wish there is the sample code for this, but couldn't find it.