Skip to content

Instantly share code, notes, and snippets.

@anupamchugh
Created June 23, 2020 09:17
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save anupamchugh/8b708810559d95c845d1ca595f4590a1 to your computer and use it in GitHub Desktop.
Save anupamchugh/8b708810559d95c845d1ca595f4590a1 to your computer and use it in GitHub Desktop.
struct ContentView: View {
var body: some View {
ScrollView(.horizontal) {
LazyHStack(spacing: 10) {
ForEach(0..<1000) { index in
Text("\(index)")
.frame(width: 100, height: 200)
.border(Color.gray.opacity(0.5), width: 0.5)
.background(Color.blue)
.cornerRadius(6)
}
}
.padding(.leading, 10)
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment