I am currently building an application using Firebase.
This is one of those message boards that can be seen anywhere on the Internet.
But there was one problem.
This is a matter of sorting by date.
I want to look at a recent date first, but I always see only the data that I created in the first place.
postRef.orderByChild('createData').startAt(reverseDate).limitToFirst(1).on('child_added',(data)=>{
console.log(data.val().name + data.val().createData);
})
result β hello1496941142093
My firebase tree 
My code is the same as above.
How can I check my latest posts first?
How to order a reverse firebase database?
source
share