Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support for SnapshotOptions #955

Closed
robokozo opened this issue Nov 22, 2020 · 2 comments
Closed

Support for SnapshotOptions #955

robokozo opened this issue Nov 22, 2020 · 2 comments

Comments

@robokozo
Copy link
Contributor

What problem is this solving

When $binding to a query that contains serverTimestamp() the timestamp property will return null as described here: firebase/firebase-js-sdk#1929 (comment)

The solution suggested in the post is to include https://firebase.google.com/docs/reference/js/firebase.firestore.SnapshotOptions.html

Which can be applied to the .get({ serverTimestamps: "previous" }) or the .data({ serverTimestamps: "estimate" }) on the snapshot.

Proposed solution

Allow the user to pass down the snapshotOptions when setting up a $bind

Describe alternatives you've considered

Add additional logic around the code that consumes the data to expect the first response to include null

@pmalbu
Copy link

pmalbu commented Jul 14, 2021

Has any progress been made on this? It seems like a fairly easy feature to add. It would be really nice to get rid of my v-if="field.created" logic 🙏🏻
I would love to make the change myself and submit a PR but I'm concerned I'd screw something else up in the package... 🙈

@posva posva mentioned this issue Oct 13, 2022
43 tasks
posva added a commit that referenced this issue Oct 19, 2022
@posva
Copy link
Member

posva commented Oct 19, 2022

Implemented in 76d36f5

@posva posva closed this as completed Oct 19, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants