amplitude / Amplitude-TypeScript

TypeScript Amplitude Analytics SDK
https://amplitude.github.io/Amplitude-TypeScript/
MIT License
141 stars 40 forks source link

Offline support for React Native SDK #655

Open Mercy811 opened 10 months ago

Mercy811 commented 10 months ago

Summary

This issue is to collect customer requests on supporting offline mode for React Native SDK while Amplitude Browser SDK supports offline mode out of the box by https://github.com/amplitude/Amplitude-TypeScript/pull/644.

Leave a comment under this issue with the use causes when and why you need this feature. We will prioritize it and fit into our roadmap.

cgibson-emesent commented 10 months ago

This would be a very useful feature for React Native as it's more likely to go "offline" then other use cases. E.g, a user is using the app on a train and the 4G reception drops out (either bad area or going through a tunnel). So those events will be lost.

For our use case, the app is used in locations where internet connections are almost guaranteed to be non-existent (underground or remote areas). The phone / tablet connects to our devices WiFi to stream data and once they have completed their scan will then connect to a internet based WiFi.

Being able to keep the events in local storage until there is a successful upload of the event would be vital to us. As in, if the sending of the event fails due to a network issue, it should not be removed from the unsent collection and be available for another retry.

irby commented 4 months ago

I second the comment above. We have use cases in our mobile app where users should be able to perform certain activities offline, and we would like to capture these events in Amplitude once the user comes back online.