Replies: 1 comment
-
Following their documentation, you will arrive in something like this import { of as of$ } from 'rxjs'
const enhance = compose(
withDatabase,
withObservables(['id'], ({ database, id }) => ({
post: database.get('posts').findAndObserve(id),
})),
withObservables(['post'], ({ post }) => ({
comments: post ? post.comments.observe() : of$(null),
})),
); |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I have a screen that receives the post ID as a route parameter and would like to subscribe to all post and comment updates, how can I implement this with
findAndObserve
?Beta Was this translation helpful? Give feedback.
All reactions