02-ContentView-3.swift 374 B

12345678910111213141516
  1. import SwiftUI
  2. import Kingfisher
  3. struct ContentView: View {
  4. var body: some View {
  5. List {
  6. ForEach(0 ..< 10) { i in
  7. HStack {
  8. Rectangle().fill(Color.gray)
  9. .frame(width: 64, height: 64)
  10. Text("Index \(i)")
  11. }
  12. }
  13. }.listStyle(.plain)
  14. }
  15. }