Answer the question
In order to leave comments, you need to log in
How to cache data in Cordova application?
Good day to all.
I am developing an application using Ionic framework and Cordova.
The application makes a request to an external server, receives data in json format and displays them on the screen. The data consists of text and pictures. Pictures are pulled from the net.
You need to be able to work with the application offline. I want to cache data on my phone. What would be in the absence of the Internet. The last downloaded data was shown when there was Internet.
Plus, in addition, I did the following - when data comes from the server, they have a so-called version (current date and time). If the "version" has not changed, then do not update the data.
Actually the question is how to implement it. Pictures and text are not large. If there was just a text - At least I threw it into the local storage and that's it. But what about the pictures? I need to somehow load them inside the application.
Maybe someone has an idea?
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question