You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Should data be cached for when there is no connection? Something like the hive dart pub package could be used for this.
Some things that could be cached:
Profile data (bio, username, display name, etc.).
A couple of your recently seen posts from the feed (trending & recents).
The daily hottest posts.
The list of users you've previously messaged & a few of your recent messages with them.
This could be implemented by checking if you are connected to the internet or not (via the already added connection checker dart pub package. Then, if you are connected, load data from the server. If not, load it from the cache. Data received from the server would also be immediately cached.
An example of an app that does caching like this is Instagram. However, on the other hand, other apps don't. Reddit has basically no data persisted if you're offline (all you get are error messages).
The text was updated successfully, but these errors were encountered:
Should data be cached for when there is no connection? Something like the hive dart pub package could be used for this.
Some things that could be cached:
This could be implemented by checking if you are connected to the internet or not (via the already added connection checker dart pub package. Then, if you are connected, load data from the server. If not, load it from the cache. Data received from the server would also be immediately cached.
An example of an app that does caching like this is Instagram. However, on the other hand, other apps don't. Reddit has basically no data persisted if you're offline (all you get are error messages).
The text was updated successfully, but these errors were encountered: