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
Passing a query to useCollection gives warning "could not get path of the data source" #1315
Comments
For queries, you need to pass an |
@posva I suppose it doesn't matter that I'm not using SSR? |
Not yet 😄 Lines 42 to 47 in 66f42ed
|
I'm also not using SSR (ssr: false in Nuxt config) and get this SSR related warning. Ideally, if no SSR is being used, there wouldn't be any warning related to it. |
+1 here. I am also seeing this warning and not using SSR at all. Using latest VueFire 3.1.13 version. |
does anyone know what the |
it must be a unique key across your application |
I'm not using SSR and I need to get rid of this warning. Please fix this. |
Demanding a maintainer fix something like this is not a good way to encourage them. First, you should explain exactly why you need to get rid of the warning, because usually warnings don't affect anything. Second, you can already get rid of the warnings based on the links to documentation above. For example https://vuefire.vuejs.org/guide/ssr.html#Manual-SSR-keys explains that you can manually set an SSR key. This will make it go away useCollection(queryRef, { ssrKey: 'my-quiz' }) Finally, consider sponsoring Posva so that he can reach his sponsorship goal and work on his open source projects full time. https://github.com/sponsors/posva |
I wish there was a better way. Thanks for help. |
How about adding more details to the warning message? The current warning,
|
From what I can gather they plan to fix this by hiding the message for those not using SSR. The fix just hasn't been released yet. Maybe creating a PR would be helpful for the repo owner. Adding the |
Reproduction
coming soon
Steps to reproduce the bug
vuefire@3.1.0
pending
resolves early causing any templates that depend on it to flash momentarily before being replaced with data.[VueFire SSR]: Could not get the path of the data source
Expected behavior
I would expect that passing a query to useCollection would behave the same as passing a raw collection.
Actual behavior
Additional information
I set a breakpoint in the source. Here's the result in Chrome Dev Tools with some of the local context showing.
The text was updated successfully, but these errors were encountered: