How to Cache API Responses with Ionic & Capacitor

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

Simon Grimm

Simon Grimm

Күн бұрын

Пікірлер: 34
@behicsakar
@behicsakar Жыл бұрын
bro thats mindblowing tut. full of observables subscribers and first time i see the browser 20min later you start to type and type and type…
@RahulKumar-dm5zy
@RahulKumar-dm5zy 3 жыл бұрын
awesome video sir. thanks for making this video
@KrelfallahHichem
@KrelfallahHichem 3 жыл бұрын
Excellent video, thank you
@SmartiePantsShop
@SmartiePantsShop 3 жыл бұрын
Hi Simon, thanks for this, it was very very handy. But a quick question, between your examples over the last years, you've swapped between Capacitor Storage and Angular Storage and SQLite - is there a reason as to why I should use one over the other, are there any performance benefits or pitfalls I should be aware of. Thanks for the many many helpful videos.
@galaxies_dev
@galaxies_dev 3 жыл бұрын
Either you have a virus on my Mac or I can predict the future - working on a video EXACTLY on that to clarify which to use in which situation!
@HurikaneTv
@HurikaneTv 3 жыл бұрын
Proud Academy Member 😊😊😊😊
@Marshall86MT
@Marshall86MT 3 жыл бұрын
very interesting video, as usual :) I use capacitor storage instead of the cordova plugin, what do you think?
@galaxies_dev
@galaxies_dev 3 жыл бұрын
Sure would work as well, but I found managing it a bit more complicated then directly working with JSON data in Ionic Storage.
@Marshall86MT
@Marshall86MT 3 жыл бұрын
@@galaxies_devIt's an honour to get your feedback 🙏🏾 yeah that's true but since I moved to capacitor I'm trying to use it as much as possible.
@farbod6450
@farbod6450 3 жыл бұрын
This video is very helpful. Thank you
@galaxies_dev
@galaxies_dev 3 жыл бұрын
You're welcome!
@kareemadel1649
@kareemadel1649 2 жыл бұрын
can i do that with ionic-cordova app ??
@cortesdepodcast8254
@cortesdepodcast8254 3 жыл бұрын
Would be nice to compare capacitor 3 with cordova to know which one is faster, smaller and have less bugs.
@graphicsjay
@graphicsjay 3 жыл бұрын
Anyone that's worked with Capacitor after working with Cordova knows its a much better experience. Every time i would open a cordova project (pre-Capacitor), I would have multiple issues to resolve before I could actually get to work. Capacitor hasn't been that way at all.
@vincenzodamico3054
@vincenzodamico3054 3 жыл бұрын
💙💙💙💙 CACHIIIIIINNNN!!! 💙💙💙💙
@flyclaim
@flyclaim 3 жыл бұрын
Does it also work for capacitor android applications or just the web ones? I tried several variants in the android app and it doesn't seem to work and the cause is that it is served on HTTP instead of HTTPS
@faqruddinmohammad1411
@faqruddinmohammad1411 2 жыл бұрын
Hi Simon, Nice informative content. But how Can I update the cache storage if api is having updated data ? Having offline storage great for app to improve performance. But in realtime api data always have changes. So once there is changes in api data, Is any way to update the offline cached data ? So user can see always real data... Thank you
@galaxies_dev
@galaxies_dev 2 жыл бұрын
You would have to come up with your own logic to handle the validation of your cache, so maybe expire it after some time or otherwise use a service worker with a specific caching strategy!
@faqruddinmohammad1411
@faqruddinmohammad1411 2 жыл бұрын
@@galaxies_dev thanks simon. Can I have any example for service worker ?
@NoNdAs90
@NoNdAs90 3 жыл бұрын
What's the difference to do all that to localStorage instead to that that you show ? Thank you for the video :)
@galaxies_dev
@galaxies_dev 3 жыл бұрын
On a device, it will use SQLite because that data won't be cleared by the OS, which can happen if you simply store it inside localstorage.
@NoNdAs90
@NoNdAs90 3 жыл бұрын
@@galaxies_dev could you explain it more because I do not the the point exactly? Thank you again for your answer 😁
@EvTIC
@EvTIC Жыл бұрын
sorry i am using ionic react capacitor, api php and phpmyadmin. nothing appear in my phpmyadmin
@IRFANSYOUTUBE
@IRFANSYOUTUBE 3 жыл бұрын
Hi, Working on Ionic Ecommerce Project, Looking for IONIC templates free/paid to sppedup the work. Please help
@iescape3372
@iescape3372 3 жыл бұрын
Someone should make a channel like this, but for Vue & React. Having to watch these angular based tutorials, which by the way are great, is painful as I then have to figure out how to convert it to my preferred front end framework
@galaxies_dev
@galaxies_dev 3 жыл бұрын
I totally agree. If I had started with all of this about a year ago, I'd have made it 100% about Vue or React as there's basically no content out there yet. But since almost all followers in here are interested in Angular, it's not really a good idea for me right now to create Vue/React content although I'd love to :/
@chizuru1999
@chizuru1999 2 жыл бұрын
@@galaxies_dev do what you feel like. ☺️ Tho i would watch more angular for sure! 👍🏻
@TheSaceone
@TheSaceone 3 жыл бұрын
Favourite day = Tuesday. No wonder why.
@DavideCampello
@DavideCampello 3 жыл бұрын
the problems come when you need to create, update or delete the data
@victorm9131
@victorm9131 3 жыл бұрын
Well in this case don’t use cache on those APIs. Caching mechanism makes sense for data that isn’t likely to be changed in a while like dictionaries / objects that have the same shape etc.
@user-ms13w
@user-ms13w 3 жыл бұрын
dinamics or statics ..... caches.match( '/offline.html') 👍
@user-ms13w
@user-ms13w 3 жыл бұрын
kzbin.info/www/bejne/n5fVoICNlKtnicU 👈
@jhonyxf
@jhonyxf 3 жыл бұрын
how to solve this error? ERROR Error: Uncaught (in promise): TypeError: Cannot read property 'addListener' of undefined TypeError: Cannot read property 'addListener' of undefined at new ApiService (api.service.ts:18)
How to Cache Image Files with Ionic & Capacitor
23:10
Simon Grimm
Рет қаралды 12 М.
How to Handle User Roles in Ionic Apps with Guard & Directives
36:30
"Идеальное" преступление
0:39
Кик Брейнс
Рет қаралды 1,4 МЛН
«Жат бауыр» телехикаясы І 30 - бөлім | Соңғы бөлім
52:59
Qazaqstan TV / Қазақстан Ұлттық Арнасы
Рет қаралды 340 М.
Жездуха 41-серия
36:26
Million Show
Рет қаралды 5 МЛН
24 Часа в БОУЛИНГЕ !
27:03
A4
Рет қаралды 7 МЛН
Why I Stopped using Service Workers
11:44
Ben Awad
Рет қаралды 90 М.
Ionic & Capacitor for Building Native Mobile Apps - Full Course for Beginners
3:10:14
Don't Use Websockets (Until You Try This…)
6:46
Code With Ryan
Рет қаралды 327 М.
Solving one of PostgreSQL's biggest weaknesses.
17:12
Dreams of Code
Рет қаралды 222 М.
How to Integrate Supabase in Your Ionic App
44:34
Simon Grimm
Рет қаралды 8 М.
Advanced offline caching techniques in Cloud Firestore
12:34
Firebase
Рет қаралды 19 М.
I tried 8 different Postgres ORMs
9:46
Beyond Fireship
Рет қаралды 443 М.
Uploading Files to Supabase with Ionic using Capacitor
51:41
Simon Grimm
Рет қаралды 3,8 М.
"Идеальное" преступление
0:39
Кик Брейнс
Рет қаралды 1,4 МЛН