How to remove “row” separators/dividers from a List in SwiftUI?

前端 未结 7 2401
渐次进展
渐次进展 2020-12-05 04:35

I\'m trying to remove the "row" separators (known as dividers in SwiftUI) from a List in SwiftUI.

I went through the List document

7条回答
  •  醉梦人生
    2020-12-05 04:47

    iOS 13 builds only:

    The current workaround is to remove them via UIAppearance:

    UITableView.appearance(whenContainedInInstancesOf: 
        [UIHostingController.self]
    ).separatorStyle = .none
    

提交回复
热议问题