-
-
Save sturdysturge/000d5d657c57f026081d2fb65374ac30 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import SwiftUI | |
@available(iOS 16.0, *) | |
struct ContentView: View { | |
let rows: [GridRowContent] = [ | |
GridRowContent(items: ["A", "B", "C", "D", "E"]), | |
GridRowContent(items: ["F", "G", "H"]), | |
GridRowContent(items: ["I", "J", "K", "L", "M"]) | |
] | |
var body: some View { | |
Grid { | |
ForEach(rows) { row in | |
GridRow { | |
ForEach(row.items) { item in | |
Text(item.text) | |
} | |
} | |
} | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment