Lazy loading & image caching with UITableView swift 5 Hindi tutorial

preview_player
Показать описание
Lazy loading in swift along with image caching in swift are two most important topics and the most commonly used feature in any iOS application. For the demo, we are fetching images from an API and displaying them in a UIImageView inside the UITableView.

Many beginners when displaying image from the server face the problem of UITableView freeze or having a glitch while scrolling the UITableView

In this video, I will present an example where we use lazy loading with UITableView in swift to resolve that issue. Along with lazy loading, I will also explain how we can cache an image in swift using NSCache.

Now it's important that I say that I am just explaining the general concept of lazy loading and image caching here with a small example of what they are and what problem they solve.

There are way better libraries that you can use which handle many complex scenarios for lazy loading an image like the one I mention in this video which is SDWebImage.

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

✅ Subscribe to the channel and stay ahead of everyone by following the right way for writing clean code in swift. 🔥🔥🔥🔥🔥

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

-----------------------------------------------------------------------------------------------------------------------
📥 Download the source code from

-----------------------------------------------------------------------------------------------------------------------

############################################

Connect with me on social media

###########################################

#lazyloadingInSwift #imageCachingInSwift #lazyLoadingExample
Рекомендации по теме
Комментарии
Автор

I hope this video answers most of the questions regarding why does the UITableView freezes when you try to set an image from a URL, this video will help you to understand the concept of lazy loading in swift along with a basic example of image caching using NSCache, however lazy loading with UITableView can get tricky and I have tried my best to answer most of it in the video but if I missed something then please feel free to ask your question as comments or reach out to me I will be happy to answer your questions :)

CodeCat
Автор

Hello Ravi,
You are not only a good programmer but also a very good teacher.
Thank you very much for making videos.
👍👍👍👍

sayyedaamer
Автор

I was missing this video due to hectic schedule. Honestly, today i watched this video and I came to know i was facing this issues in the project and finally I resolved it by today itself. Always love to watch your videos and it is very helpful. The unique thing I like is your deep and clear explanation.
Thanks always to you 😊

jayprakashsharma
Автор

Ravi sir Thanks for sharing perfect example for lazy loading. I really want to learn more new things from your videos. :))

MandeepSingh-lyjj
Автор

Very well explained the concept of lazy loading of images

rakeshmahato
Автор

Really it's great explanation . Your teaching style is unique . Thank you very much for your support.

sambit
Автор

thank you that was a great video i love Your teaching style

saadaltwaim
Автор

Neat, precise explanation and clean coding. .

prasanthmadhavanath
Автор

Tnx sir, Eventually, I found the answer to storing the image in NSCache.
but I also prefer a sdwebimage for download the image

AmitGupta-efnm
Автор

Well explain ravi.. Keep up the great work.

DigitalHole
Автор

I came after having this question in interview :-)

JunaidKhan-nytu
Автор

Please make a video on Diffabledatasource with sections.

razakhan
Автор

Please make a video on handling Network and Image Size

UmairKhan-tqhq
Автор

Hello Ravi sir,
Hope you are doing well!!

Can we have one video dedicated on socket applications for video calling apps.

abhishekdhiman
Автор

Could you please explain thoroughly how to use third party libraries into our xocde project..!!

mahii_lyricz
Автор

Hello Sir, Is my understanding correct ?
You have created NSCache as instance stored property so, the imageCache will store only caching for urls this instance has called. For example 
Let tableViewCell A load image from url -> xyz
and tableViewCell B load image from url -> abc
if now tableViewCell A try load image from url -> abc then it will not find image in cache hence load from server

Am I correct ?

lordironman
Автор

Nice video thanks, one question -- Third parties like Kingfisher automatically handle caching? or we have to do it manualy.

AnkitSoni
Автор

Please make video on loading and image caching in swiftui

Rasikabharati
Автор

please make a video on Dynamic Links and Databse

madhavandkartikshow
Автор

Hi i am not able to get video for urlCache @Ravi

poojaraghuwanshi
join shbcf.ru