I have the following challenge and I hope somebody can help:
I have a Firebase-collection with notifications and I want to show them in a listview with the relative date as header. But: If the header appears more than once, it only should show it the first time.
I think an image explains it better:
This is how it looks now - but I want the "vor ~1 Tag" and the "vor 5 Tagen" to show only once.
The simplest I thought is to just show it with a conditional - but how do I compare the current date with the one before; especially the "relative" one?
My 2nd solution would be to query the collection in a custom action - but also this way I'm not sure how to group by a relative date.
Does anybody have an idea?
Thanks!