CSFrequency / react-firebase-hooks

React Hooks for Firebase.
Apache License 2.0
3.6k stars 306 forks source link

Elegant way to combine useListKeys and useObject #175

Closed matthieunelmes closed 3 years ago

matthieunelmes commented 3 years ago

So I have a list of keys that I can obtain with the database useListKeys hook.

I then want to iterate through the keys to return each relevant object. Any help would be much appreciated.

chrisbianca commented 3 years ago

@matthieunelmes apologies for the delayed response. I would suggest you have two components, one loading the list of keys using useListKeys and the rendering a list of child components which uses useObject