How to fill RecyclerView Adapter with Firebase

后端 未结 2 1281
逝去的感伤
逝去的感伤 2020-12-05 14:42

I made a lot of research, but I couldn\'t find any resource how to use Recycler View with Firebase(or vice versa)

There is one Firebase list adapter whi

相关标签:
2条回答
  • 2020-12-05 15:16

    you can use the FirebaseUI-Android, it is developed by Firebase itself which is quite useful.

    The link shown as below.

    https://github.com/firebase/FirebaseUI-Android/blob/master/database/README.md

    0 讨论(0)
  • 2020-12-05 15:19

    For the moment you will have to provide your own implementation of the RecyclerView.Adapter.

    You can use the FirebaseListAdapter for inspiration or roll your own.

    Here's a chat app that uses a RecyclerView: https://github.com/thaleslima/Chat-Firebase/tree/master/app/src/main/java/com/gdgcampinas/chat_firebase

    Update

    There is now a library called FirebaseUI that includes a FirebaseRecyclerAdapter and much more. I highly recommend that you use that one in your apps or as the basis for an adapter that suits your needs.

    0 讨论(0)
提交回复
热议问题