I want to improve the performance of my app. My app fetches JSONP data from my server. My question now is how is the best practice for doing data updates and saving data for offline mode?
My current workflow was the following:
- Fetch data from JSONP-Api if device is online
- Sync it to an localStorage-Store
- set an timestamp for last data update
- on next store.load() check if a defined time interval has passed since the last update
Are there any improvements or better logic I can implement to do data updates?
How can I send only changed data from the server, and replace/update it in the app?
In my current app project I have different stores:
- assetdata (link to attached images/pdfs)
By now I have a JSONP proxy for each store. Could i reach a better performance if the server would send a nested json which holds the data of all stores by doing only one http request than three?