SwiftUI List の色を変更する

例えば、こういったコードで

List {
  Text("Melon")
    .listRowBackground(Color.green)

  Text("Banana")
    .listRowBackground(Color.yellow)

  Text("Apple")
    .listRowBackground(Color.red)

  Text("Prune")
    .listRowBackground(Color.blue)

  Text("Grape")
    .listRowBackground(Color.purple)
}
.foregroundColor(Color.white)
.onAppear {
  UITableView.appearance().backgroundColor = .lightGray
}
.onDisappear {
}


こんな感じで、項目(Row)の背景色と、リスト自体の背景色が変えられる。


List の背景は appearance を使用する以外に、簡単に変更できる方法はないのかしら。。



補足。
このサンプルのプロジェクトは GitHub にある。
https://github.com/daisuke-t-jp/SwiftUIListColorSample