GIS.ly uses a Manager Pattern in order to perform CRUD operations with Tracks.
The following illustrates how Tracks are edited in the application using a Track Manager with the following steps:
Get Track from React state hook.
Inject Track into manager object.
Call manager methods, which might alter the Track. Additionally, a fresh copy of the Track is returned as a result. This may update the hooked GeoJSON object. See ref: updateTrack for more details on how.
Update relevant React state hooks with modified Track. See ref: updateFromTrack sequence diagram for more detail.
Attachments:
Screen Shot 2023-11-09 at 12.20.34 PM.png (image/png)
Screen Shot 2023-11-17 at 4.17.03 PM.png (image/png)
Screen Shot 2023-11-17 at 4.17.03 PM.png (image/png)