GiumaSoft
(Giuseppe Mazzilli)
1
I'm going mad to understand how List works internally, and how can i encapsulate or modify RowContent at that conditions.
struct PlaceList<SelectionValue, Content> : View where SelectionValue : Hashable, Content : View {
private let content: Content
var body: some View {
content
}
}
extension PlaceList where SelectionValue == Never {
@MainActor init<Data, ID, RowContent>(_ data: Data, id: KeyPath<Data.Element, ID>, @ViewBuilder rowContent: @escaping (Data.Element) -> RowContent) where Content == ForEach<Data, ID, RowContent>, Data : RandomAccessCollection, ID : Hashable, RowContent : View {
...
}
}
ahti
(Lukas Stabe 🙃)
2
The usual caveats about underscored/private API apply, but I believe this blog post should answer your questions.
GiumaSoft
(Giuseppe Mazzilli)
3
Thanks for helpful comment, i got a look on your link, it clarify that behind the scene SwiftUI API can manipulate content in a way is not possible for devs.
/GM