Regarding real-time location update in my app

Actions & Logic

Hi Flutterflow gurus! I'd like to pick you brain on how to get real-time location update and then update the UI according.

Basically what I wanna achieve is to have a Map view (using the GoogleMap widget) which users can use to track their jogging route. The user would click a button to start jogging which would start the location tracking (both foreground and background). The app would store the location update (Latlng) in memory as the location changes (preferably using a distance threshold like 10 meters, if not achievable, periodical would suffice). Meanwhile a polyline is drawn with each update between the Nth location and the (N-1)th location. Then when the user finishes jogging and click a "Stop" button, the app would take the stored array of Latlng and process them and finally send to firestore.

Thank you in advance!

What have you tried so far?

I'm mostly stuck at how to achieve the "real-time update" part.

Did you check FlutterFlow's Documentation for this topic?
Yes
1
2 replies