It is me again. I think I finally found the true reason and a correct fix for the issue.
For a List embedded in a NavigationView, the default listStyle is set to an inset style for some unknown reasons, which in other words, the list is default to have padding around it. In order to solve the issue, just simply add a .listStyle after the List view to set another style which is not inset.
In my case, I use .listStyle(GroupedListStyle()). The padding would be gone now. You may look in the documentation about the listStyle.
Topic:
Developer Tools & Services
SubTopic:
Xcode
Tags: