For you to be able to query using date fields, you need to compare a date - in this case, the date field from your document - to a date as well. The 0
is not considered a number 0, so this affects the comparison.
It needs to be something like this: where("date", ">", new Date())
. In case you want to compare dates based in epoch timestamp, a good solution is convert the new date using the where like this: where("date", ">", new Date(epoch*1000))
as mentioned. Once you using comparison in the where
part of the query, the returns should occur correctly.
Besides that, more examples of converting timestamps
for Firestore can be found here.