No video

SwiftUI Grids - LazyVGrid, LazyHGrid, Static Grid

  Рет қаралды 9,787

Sean Allen

Sean Allen

Күн бұрын

Go to squarespace.com/seanallen to save 10% off your first purchase of a website or domain using code SEANALLEN.
Today you will learn about LazyVGrids, LazyHGrids and static Grids (introduced in iOS 16). I will show you the differences between them and when to use each one. I start by explaining how LazyVGrids work with various column spacing parameters and pinned section headers. The we cover LazyHGrids followed by static Grids.
My iOS Dev Courses:
seanallen.teachable.com/
My Source Code:
seanallen.teachable.com/p/sou...
X (Twitter):
Sean Allen - / seanallen_dev
Hired.com:
hired.com/x/1n01g
Book and learning recommendations that help out the channel if you decide to purchase (Affiliate Links):
Mark Moeyken’s SwiftUI Books:
www.bigmountainstudio.com/a/f...
Paul Hudson's Hacking With Swift:
gumroad.com/a/762098803
RocketSim - Enhance Your Xcode Simulator:
gumroad.com/a/51797971/ftvbh
Objc.io Books (Thinking in SwiftUI & Advanced Swift):
gumroad.com/a/656585843
Timestamps:
0:00 - LazyVGrids, LazyHGrids, Static Grids
0:15 - Grids need Data (an array)
1:01 - Basic LazyVGrid (Vertical)
3:31 - What does Lazy mean?
3:58 - Flexible Columns
6:05 - Fixed Width Columns
6:40 - Adaptive Columns
8:07 - Spacing between items
8:51 - Pinned Section Headers
9:58 - LazyHGrids (Horizontal)
12:43 - Static vs. Lazy Grid Differences
13:29 - Common use of static Grids
13:55 - Basics of static Grids
15:38 - Spacing between elements
15:50 - Modifiers for customization
#swift #softwaredeveloper #iosdeveloper

Пікірлер: 36
@seanallen
@seanallen 4 ай бұрын
Learn more SwiftUI, Swift & UIKit with my iOS developer courses at seanallen.teachable.com
@gangalo68
@gangalo68 4 ай бұрын
Did you hack my search history?! 😄
@seanallen
@seanallen 4 ай бұрын
Yup
@MassonLifestyle
@MassonLifestyle 3 ай бұрын
I just saw on Twitter that you got a full time job, congrats! You will be missed in here as you demystify half of this stuff for me. But with that being said, I'm happy for you. I can see why you would want to work with a team. Coding alone can get somewhat lonely sometimes and it's good to collaborate with others.
@seanallen
@seanallen 3 ай бұрын
KZfaq videos won't stop :). I can still knock them out on nights and weekends.
@guilhermeteixeirademello4907
@guilhermeteixeirademello4907 4 ай бұрын
Another day, another amazing video! Seriously, you and Paul are the bests in the game!!!
@seanallen
@seanallen 4 ай бұрын
I appreciate that!
@kwkistler
@kwkistler 4 ай бұрын
Thank you, Sean, fantastic tutorial I enjoy your teaching style, clear to the point. Keep up with the great content!
@seanallen
@seanallen 4 ай бұрын
Much appreciated!
@nileshjdarji
@nileshjdarji 4 ай бұрын
All grids nicely summed up. 👍
@byhabiboff
@byhabiboff 2 ай бұрын
I love You Sean Allen. Even though it's a subject I know, I always learn something every time I watch your videos.
@seanallen
@seanallen 2 ай бұрын
I appreciate that!
@mario_luis_dev
@mario_luis_dev 4 ай бұрын
masterful explanation as always Sean, keep up the great work 🤝
@seanallen
@seanallen 4 ай бұрын
Appreciate it!
@emmanuelecorporente
@emmanuelecorporente 4 ай бұрын
Nice explanation!
@seanallen
@seanallen 4 ай бұрын
Glad it was helpful!
@ibringit
@ibringit 2 ай бұрын
thank sean
@seanallen
@seanallen 2 ай бұрын
Happy to help!
@elijahsmith5315
@elijahsmith5315 4 ай бұрын
elite video.
@seanallen
@seanallen 4 ай бұрын
Glad you liked it :)
@tariqAlmazyad
@tariqAlmazyad 4 ай бұрын
Last important info , what if you have last color as by itself ( as Array of 3 or 5 or 11 ) and you want you center it at the bottom of the view. Kinda trying to look for the best possible way to handle it .
@konstantin215
@konstantin215 3 ай бұрын
Nice guide. But what about waterfall layout?
@zaid.qattan
@zaid.qattan 3 ай бұрын
Can you please do a full course or a BootCamp for SwiftUI?
@seanallen
@seanallen 3 ай бұрын
Check this out - kzfaq.info/get/bejne/mJefdpqksa_LoH0.html
@X_BOZO
@X_BOZO 4 ай бұрын
Thank you, but I have a question: how do I make them like buttons in all the pictures?
@seanallen
@seanallen 4 ай бұрын
Can you elaborate on what you mean? I don’t understand the question.
@X_BOZO
@X_BOZO 4 ай бұрын
@@seanallen I mean, how do I make this grid like an action
@w0mblemania
@w0mblemania 3 ай бұрын
@@X_BOZO Just make each element a Button. Or, you can just add tap gestures to each element in the grid.
@josiasmayo7203
@josiasmayo7203 6 күн бұрын
ScrollView(.horizontal){ LazyHGrid(rows: rows, content: { ForEach(MockData.colors,id:\.self){ number in NavigationLink(destination: EmptyView() ){ RoundedRectangle(cornerRadius: 10) .fill(Color.red) .frame(width: 100) } } }) }
@KathiresanMurugan
@KathiresanMurugan 2 ай бұрын
Super
@seanallen
@seanallen 2 ай бұрын
Thanks
@victorriurean
@victorriurean 4 ай бұрын
@app1.cpu.ru.internet
@app1.cpu.ru.internet 4 ай бұрын
Thanks!
@seanallen
@seanallen 4 ай бұрын
I appreciate the generosity!
SwiftUI Pie & Donut Charts - New in iOS 17
9:55
Sean Allen
Рет қаралды 4,7 М.
NavigationStack - SwiftUI Programmatic Navigation - iOS 16
20:20
ЧУТЬ НЕ УТОНУЛ #shorts
00:27
Паша Осадчий
Рет қаралды 10 МЛН
MISS CIRCLE STUDENTS BULLY ME!
00:12
Andreas Eskander
Рет қаралды 20 МЛН
Schoolboy - Часть 2
00:12
⚡️КАН АНДРЕЙ⚡️
Рет қаралды 4,5 МЛН
Your App Will Get Rejected | New Privacy Rules - 2024
11:26
Sean Allen
Рет қаралды 35 М.
SwiftUI Card View - Group Box & Customizations
10:21
Sean Allen
Рет қаралды 13 М.
The perfect imperfection of Google's Material You
15:47
David Imel
Рет қаралды 425 М.
Swift Algorithms - Faster, Cleaner Code. (Chunked Example)
13:48
3D Content in iOS & visionOS apps with Spline (Xcode & SwiftUI)
16:21
Stop using GeometryReader in SwiftUI
4:27
Flo writes Code
Рет қаралды 4,3 М.
WWDC23: Beyond scroll views | Apple
14:47
Apple Developer
Рет қаралды 31 М.
Super Power Scroll Views - SwiftUI - iOS 17
9:14
Sean Allen
Рет қаралды 25 М.
ЧУТЬ НЕ УТОНУЛ #shorts
00:27
Паша Осадчий
Рет қаралды 10 МЛН