iosswiftuitablevieweditmode

What is "Edit Mode" in swift in the context of TableViews?


I have been messing around with EditMode in swift TableViews for a bit am looking for some clarification about it. What exactly does entering EditMode do? I know that it allows you to delete and move elements in a TableView but I also noticed that other functions of a TableView are limited when isEditing is set to true. For instance, if you tap a cell the didSelectRow function does not trigger. Is this an intended behavior of activating EditMode?


Solution

  • The reason didSelectRow did not trigger is because the variable allowsSelectionDuringEditing is set to false by default. By setting it to true I fixed my problem.