I am creating an app that needs to delete documents automatically after a timer that is stored inside of the document expires but I am not seeing any data types that support a timer, the closest thing I found was an integer but I am not exactly sure on how I would go about updating that every second. Here is an example of my previous attempt at adding a timer as a field.
FirebaseFirestore.instance.collection("docs").add({
"timer:": Timer(Duration(hours: 1), () {
print('Finished');
_deleteDocument();
})
});