Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Collections and rendering #329

Unanswered
maxkrieger asked this question in Q&A
Discussion options

If I use useFirestoreCollectionData in a top level component to render a list of many items, how over-zealous will react be about rendering? I learned about this general pitfall of high level state while watching the Recoil demo talk.

Ideally, a single item component re-renders on update, but not the whole list. (削除) Is there a way to only grab, say, the IDs of a collection and not re-render if there are doc updates to that collection? Is useMemo the only way? (削除ここまで) EDIT: I assume useFirestoreCollection is what I actually want, and the snapshot only changes when keys are added/removed. Just looking for confirmation now!

Might be a good addition to the docs to note this difference between useFirestoreX and useFirestoreXData

You must be logged in to vote

Replies: 0 comments

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
1 participant

AltStyle によって変換されたページ (->オリジナル) /