How to build a UICollectionView like the App Store

  Рет қаралды 41,687

Paul Hudson

Paul Hudson

4 жыл бұрын

iOS 13 introduced powerful new collection view features, including UICollectionViewDiffableDataSource and UICollectionViewCompositionalLayout, so in this video I walk you through how to use these features and more to make a collection view that looks just like Apple's App Store.
You can find the source code for this project on GitHub: github.com/twostraws/TapStore
If you want to find out more about what's new in iOS 13, I've put together a massive collection of code samples here: www.hackingwithswift.com/arti...

Пікірлер: 86
4 жыл бұрын
Do you sleep sometimes?
@rebeloper
@rebeloper 4 жыл бұрын
This takes an already fantastic UICollectionView to the next level. Well done Steve Breen and awesome video Paul!
@cary98029
@cary98029 4 жыл бұрын
That was an amazingly well-executed example project tutorial video on UICollectionViews. I am now interested in using collection views again! Thanks, Paul!
@laurentb6563
@laurentb6563 4 жыл бұрын
amazing video, really appreciated. I did watch the WWDC talk but I did not understand as much as in your video with all your practical examples! super cool 👍🏻
@pieterbikkel
@pieterbikkel 4 жыл бұрын
Just what I need for my project, the uicollectionview full size. Great work 👍🏻
@marcosatanaka
@marcosatanaka 4 жыл бұрын
Amazing! I'm about to refactor a section of my app that'll have a similar UI, and your video has helped me understand a lot of these new collection view APIs. Thank you!
@TryToTellMyName
@TryToTellMyName 4 жыл бұрын
Awesome video Paul! My favorite feature is the diffable datasources and the new compositional layouts. This video helps a lot how the new layout work, thank you.
@michaelutech4786
@michaelutech4786 2 жыл бұрын
Paul, I positively admire your presentation skills. This is so to the point, clear, informative, vivid. I know how much work it is to prepare such a tutorial, what you do looks so utterly effortless and casual. Please make tutorials on how to make tutorials! ;-) Amazing!
@pieterbikkel
@pieterbikkel 4 жыл бұрын
UICollectionView is definitely my favorite
@yoellev5191
@yoellev5191 4 жыл бұрын
Love it, Thanks for yet another great tutorial Paul.
@fish1962d
@fish1962d 4 жыл бұрын
SwiftUI is still my favorite new iOS 13 feature but this video is fantastic! Thank you so much for all you do for the community!
@sashamakedonskii
@sashamakedonskii 4 жыл бұрын
Great tutorial! Thank Paul for your work
@Carlos.Damiao
@Carlos.Damiao 4 жыл бұрын
Amazing video Paul! That barely relates to what I do with Collection Views. Will definitely see the WWDC talks you suggest and clone your git repo. Thanks a bunch man, your content is priceless!
@gakkieNL
@gakkieNL 4 жыл бұрын
Thank you Paul! Excellent stuff. You really are THE source on Swift! Really appreciated! EDIT: I did find using type as a property of Section confusing (section.type vs Section.type). Took me a while to see that ...
@theafzalansari01
@theafzalansari01 4 жыл бұрын
Thanx Paul it’s pretty detailed and help alot to design collection Views clear some doubts regarding it
@acmcj
@acmcj 4 жыл бұрын
Great video Paul. Would be amazing to see v2 of this where you use self sizing cells etc rather than hard coding the heights
@shaileshchandavar874
@shaileshchandavar874 4 жыл бұрын
You nailed it Paul, You connected all dots together. Kudos :👍🏻👍🏻👍🏻👍🏻👍🏻
@thecalver
@thecalver 4 жыл бұрын
very nice tutorial of these new features mate.
@avazbekolimov5739
@avazbekolimov5739 Жыл бұрын
amazing video thanks for such valuable masterclass videos!!!!
@edwincreator2855
@edwincreator2855 4 жыл бұрын
thank you so much for the tutorials
@nickpappas6109
@nickpappas6109 2 жыл бұрын
fantastic video. thank you
@SandeepSingh-lg7bq
@SandeepSingh-lg7bq 4 жыл бұрын
Simply amazing...Thanks Paul
@erisonveshi8406
@erisonveshi8406 4 жыл бұрын
I am a simple man! I see an awesome free tutorial, I go to your website and buy something there!
@soromiso
@soromiso 3 жыл бұрын
Thanks you it inspires me to do something new
@ian7666
@ian7666 4 жыл бұрын
Conceptually quite simple, definitely aided by your explanations Paul, but that’s going to take some committing to muscle memory... oh, those class names 🤯 Thanks a bunch, nice work!
@fawadfarooq
@fawadfarooq 4 жыл бұрын
Amazing stuff ! THANK YOU !
@Paxeroo
@Paxeroo 4 жыл бұрын
Good and useful. Thanks!
@NormNorris
@NormNorris 4 жыл бұрын
Great video Paul. Any chance you can make a part 2 to this video that shows how to segue to a "detailed" view?
@warrybk
@warrybk 3 жыл бұрын
Awesome tutorial!
@AndrewDChristie
@AndrewDChristie 2 жыл бұрын
Pretty useful video, I like what's going on here
@watchit387
@watchit387 3 жыл бұрын
"these folks deserve our appreciation and love" ))
@atalayasa2772
@atalayasa2772 4 жыл бұрын
It is great tutorial thank you very much.
@srgdmtr
@srgdmtr 3 жыл бұрын
thanks a lot!
@rasheedm2084
@rasheedm2084 3 жыл бұрын
Amazing ♥️
@edison1
@edison1 4 жыл бұрын
Yes, more collection view less Swift UI!
@elangovanrajendran3763
@elangovanrajendran3763 3 жыл бұрын
Simply amazing..
@makwanbarzan7085
@makwanbarzan7085 4 жыл бұрын
Great! Thanks!
@Kiss3s1314
@Kiss3s1314 4 жыл бұрын
Can I ask, lets say I want to let Section take in more than just let items: [App] but instead make it generic to let it take in [Games], [Person]... etc, how would one apply generics in this case?
@-engin7033
@-engin7033 4 жыл бұрын
Great video, thanks. What's the best way to present new views by tapping items in your code ?
@aaronlikov6634
@aaronlikov6634 3 жыл бұрын
U are the best!
@gakkieNL
@gakkieNL 4 жыл бұрын
I've added a small extension to the protocol: extension SelfConfiguringCell { static var reuseIdentifier: String { return String(describing: self) } } This way we can omit to set the reuseIdentifier manually for every cell that conforms to the protocol :)
@swiftlandacademy3193
@swiftlandacademy3193 4 жыл бұрын
Oh my gosh... Nice tutorial and the woman in the meme pic is a Brazilian actress lol 😂
@liamblackburn5561
@liamblackburn5561 3 жыл бұрын
can you make a video on how to do a get json request from online rather than the file cheers. Video is amazing btw
@multitudes389
@multitudes389 4 жыл бұрын
mind blown!
@donlarson6422
@donlarson6422 4 жыл бұрын
Very cool, Paul!
@abhishekkumarthakur2116
@abhishekkumarthakur2116 4 жыл бұрын
Awesome video thank you Paul
@karljay7473
@karljay7473 3 жыл бұрын
It would be interesting to compare the exact same thing done with SwiftUI, just to see how they compare. I know some have done things like this already in SwiftUI, just gotta find one.
@Kukukuk12
@Kukukuk12 4 жыл бұрын
Awesome video, Paul 👏 I wonder why the corner radius did not work for the featured cell's image view 🤔
@twostraws
@twostraws 4 жыл бұрын
My images were slightly the wrong size, and I used aspect fit for the content mode. If you try aspect fill (i.e., stretch to fit) you'll see the corner rounding work. I should probably fix this up in the GitHub repo - it wouldn't take much.
@elifbilgeparlak1961
@elifbilgeparlak1961 11 ай бұрын
Hi Paul, I hope you can see this. If you can add the pre code so we can build with you. That would be amazing!
@donwarren3253
@donwarren3253 4 жыл бұрын
Is there any ways to do this with the new Swift UI update?
@abirhasanzoha1291
@abirhasanzoha1291 4 жыл бұрын
the corner radius for FeaturedCell's Imageview is not working as expected. can you please explain why?
@problem.solver
@problem.solver 4 жыл бұрын
a video like this come only from Paul Hudson, no one else can put so much knowlge in 50 minutes, Thanks Paul.
@shrutisharma3146
@shrutisharma3146 3 жыл бұрын
Can someone please tell me how to decide the estimated height magic number? When I tried to build this myself, I used a different number and my layout didn't turn out to be like the finished app. And I started to think my constraints in the cell might be wrong. Any help would be appreciated. Thanks.
@pieterbikkel
@pieterbikkel 4 жыл бұрын
Now I want to replicate the full-size uicollectionview, I ran into a problem, I can't find in the project where contenView is defined. Can anybody help me?
@tycoon_23
@tycoon_23 9 ай бұрын
Great efforts sir, but I noticed an issue. After implementing the UICollectionViewCompositionalLayout, the delegate methods of UICollectionView/UIScrollView stopped working. Please do share a reliable workaround.
@Byyaroff
@Byyaroff 4 жыл бұрын
Hello Paul. Thank you very much for this amazing tutorial. I faced one small problem (I think it is a bug of UICollection). All horizontal scrolled sections with Headers but without subtitles shifted right a little bit in the beginning and when I touch it or scroll this sections animated moves to their proper place. Can you please tell how to fix it? I've found this issue but non of the solutions really helped: stackoverflow.com/questions/59685203/uicollectionviewcompositionallayout-with-grouppagingcentered-doesnt-start-cente/63494677
@rajdhakate617
@rajdhakate617 4 жыл бұрын
how can i make the same thing for ios 10?
@shaneqi
@shaneqi 4 жыл бұрын
Very helpful content! Question: do you know how to get the scrolling events of orthogonal scrolling? I can use collectionView's delegate to get the scrolling events of scrolling vertically (as in the example in the video), but how can I get the scrolling events of scrolling horizontally (as in the first section of the example in the video)?
@jeffwang4448
@jeffwang4448 4 жыл бұрын
same question!
@shaneqi
@shaneqi 4 жыл бұрын
@@jeffwang4448 Alright, so I got it working by finding the scroll view for the orthogonal scrolling (it uses a separated scroll view embedded in the collection view), and switched out its delegate to my class. But I had to store its default delegate somewhere and call delegate method on it in every scroll view delegate method, otherwise it would have weird behaviors. Talk to me on Telegram if you have problems understanding what I said, my id is @ShaneQi.
@jeffwang4448
@jeffwang4448 4 жыл бұрын
@@shaneqi thank you, it's a bit hacky, but since there's no public api(at least I could not found). I think this is the only way. thank you!
@shaneqi
@shaneqi 4 жыл бұрын
@@jeffwang4448 Let's hope Apple realize it and open it up.
@ucthanhnguyen3627
@ucthanhnguyen3627 2 жыл бұрын
How can I get appstore.json. Can you give me the source please. Many thanks
@ayon3527
@ayon3527 4 жыл бұрын
I am speechless
@christostsangaris4785
@christostsangaris4785 4 жыл бұрын
Do you even use autocomplete in xCode??
@tenminutetokyo2643
@tenminutetokyo2643 4 жыл бұрын
DOOD!
@demo84demo
@demo84demo 4 жыл бұрын
Does anyone know how to then use these imageviews to transition to other view controllers? I have created buttons instead but perform segue is not available from the Cell class. @Rebeloper any ideas?
@tenminutetokyo2643
@tenminutetokyo2643 4 жыл бұрын
Dave Dempsey add an action
@nickn5206
@nickn5206 3 жыл бұрын
Did you ever manage to sort this? Ideally want to segue based on the json id but not having much luck
@demo84demo
@demo84demo 3 жыл бұрын
@@nickn5206 Yes I Did. Create the array like so: var gamesModel: [MenuItems] = [] struct MenuItems { var title: String var sbID: String var segueID: String } Then add the array items like so: gamesModel.append(MenuItems(title:"Fun Game", sbID:"Main", segueID:"funGameVC" )) sbID = Storyboard file name which contains the VC you want to move to. segueID = Segue ID you give the View controller you want to move to Then in the didSelectItemAt section use them like so: let arrayIndexRow = gamesModel[indexPath.row] let segueID = arrayIndexRow.segueID let storyboardID = arrayIndexRow.sbID let storyboard = UIStoryboard(name: storyboardID, bundle: nil) let vc = (storyboard.instantiateViewController(identifier: segueID)) self.navigationController?.pushViewController(vc, animated: true) Hope this helps as it took me a long time to figure all this out and get it working.
@nickn5206
@nickn5206 3 жыл бұрын
​@@demo84demo Thank you for this, really appreciate it.
@julianb4333
@julianb4333 4 жыл бұрын
🤯🤯🤯
@xVinoz
@xVinoz 10 ай бұрын
Once again the super zoom is driving me crazy
@donathmm3881
@donathmm3881 4 жыл бұрын
To fast for me 😩
@rebeloper
@rebeloper 4 жыл бұрын
Try Playback speed 0.25 🤣
@donathmm3881
@donathmm3881 4 жыл бұрын
Rebeloper - Rebel Developer he doesn't explain some things so I don't get everything, even tho I turn it slow.
@rebeloper
@rebeloper 4 жыл бұрын
@@donathmm3881 These will help: developer.apple.com/videos/play/wwdc2019/215/ developer.apple.com/videos/play/wwdc2019/220/
@tenminutetokyo2643
@tenminutetokyo2643 4 жыл бұрын
DOOD!
How to use the Coordinator pattern in iOS
18:12
Paul Hudson
Рет қаралды 71 М.
App Store Card Transition with Andrei Blaj,  Senior iOS Developer
1:00:01
Я обещал подарить ему самокат!
01:00
Vlad Samokatchik
Рет қаралды 9 МЛН
Ouch.. 🤕
00:30
Celine & Michiel
Рет қаралды 25 МЛН
Advanced Coordinators in iOS
18:55
Paul Hudson
Рет қаралды 41 М.
Build your next website in Swift
24:45
Paul Hudson
Рет қаралды 37 М.
SWIFT Уроки: Compositional Layout - Основы(item, group, section)
50:21
Сергей Горбачёв / cmd+B, cmd+R
Рет қаралды 6 М.
The perfect imperfection of Google's Material You
15:47
David Imel
Рет қаралды 425 М.
One of the Greatest Speeches Ever | Steve Jobs
10:31
Motivation Ark
Рет қаралды 34 МЛН
UICollectionViews in iOS with Compositional Layout
15:25
Sam Meech-Ward
Рет қаралды 6 М.
Как противодействовать FPV дронам
44:34
Стратег Диванного Легиона
Рет қаралды 88 М.
Tag him😳💕 #miniphone #iphone #samsung #smartphone #fy
0:11
Pockify™
Рет қаралды 4,4 МЛН
Xiaomi SU-7 Max 2024 - Самый быстрый мобильник
32:11
Клубный сервис
Рет қаралды 549 М.
iPhone 15 Pro в реальной жизни
24:07
HUDAKOV
Рет қаралды 496 М.