Move Disabled
Adds a condition for whether the view’s view hierarchy is movable.
Platform Compatibility
Tags
SwiftUI Code
@State var items = ["Foo", "Bar"]
var body: some View {
List($items, id: \.self, editActions: .move) { $item in
Text(item)
.moveDisabled(item == "Foo")
}
.environment(\.editMode, .constant(.active))
}