Skip to content
This repository has been archived by the owner on Dec 5, 2024. It is now read-only.

fix: ssrRef ignores null value #677

Open
wszerad opened this issue Aug 15, 2022 · 0 comments
Open

fix: ssrRef ignores null value #677

wszerad opened this issue Aug 15, 2022 · 0 comments
Assignees
Labels
bug Something isn't working

Comments

@wszerad
Copy link

wszerad commented Aug 15, 2022

πŸ› The bug
If we set ssrRef to null it becomes undefined at client-side.

πŸ› οΈ To reproduce
it's because of nullish coalescing operator:
https://github.com/nuxt-community/composition-api/blob/main/src/runtime/composables/ssr-ref.ts#L60

🌈 Expected behaviour
Treat null as "defined" value of ssrRef

@wszerad wszerad added the bug Something isn't working label Aug 15, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants