SwiftUIDragDrop
SwiftUIDragDrop copied to clipboard
"'Modified' is not a member type of 'Self'" error
The return type 'Self.Modified <DropContainerModifier>' gives this error for the functions in files: View+Draggable.swift and View+Droppable.swift.
Changing it to the below fixes the issue:
public extension View { func draggable(id: UUID) -> some View { ModifiedContent(content: self, modifier: DragElementModifier(elementId: id)) } }