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

useCookie not updating value in browser #27231

Open
martinszeltins opened this issue May 15, 2024 · 1 comment
Open

useCookie not updating value in browser #27231

martinszeltins opened this issue May 15, 2024 · 1 comment

Comments

@martinszeltins
Copy link
Contributor

Environment

Stackblitz

------------------------------
- Operating System: Linux
- Node Version:     v18.18.0
- Nuxt Version:     3.11.2
- CLI Version:      3.11.1
- Nitro Version:    2.9.6
- Package Manager:  npm@10.2.3
- Builder:          -
- User Config:      devtools
- Runtime Modules:  -
- Build Modules:    -
------------------------------

Reproduction

https://stackblitz.com/edit/nuxt-starter-kkckgc?file=app.vue

Describe the bug

When using useCookie it updates the cookie ref itself but the change is not reflected in browser devtools as can be seen in the screenshot below.

And when calling refreshCookie() it takes the value that is in the browser (old value) even when the ref value is newer.

Screenshot:
image

Additional context

No response

Logs

No response

Copy link

stackblitz bot commented May 15, 2024

Fix this issue in StackBlitz Codeflow Start a new pull request in StackBlitz Codeflow.

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

1 participant