SaveDataNetworkStatus
SaveDataNetworkStatus<DataType>: { id: "HEALTHY" } | { id: "GUEST_MODE" } | { dataBeingSaved: DataType; id: "SAVING"; lastKnownSyncedData: DataType } | { dataWeTriedToSave: DataType; error: Error; id: "FAILED"; lastKnownSyncedData: DataType }
Type parameters
A value that provides information about whether changes to the data in the SaveData object have been synced to the server.
HEALTHY
means that all changes to data in the local SaveData object have been applied on the server.GUEST_MODE
means that the user is not logged in, so changes will not be persisted to the server.SAVING
means that you have changed the data in the local SaveData object, and are currently waiting for the server to confirm that that change has been applied. Once that confirmation has been received, the network status will change toHEALTHY
.FAILED
means that a recent change to data in the local SaveData object was not able to be saved on the server. If this occurs, it is generally due to a network connectivity issue.