Closed doantu05150 closed 2 years ago
Yeah I think the type definition is incomplete, is missing the nodeCookie
so you can't reach it with typescript even if the method is indeed there.
Hello @microcipcip I'm experiencing the same issue.
Ok, I'll try patch the ts definitions, a PR is also accepted.
My first PR https://github.com/microcipcip/cookie-universal/pull/135 😁
The PR is merged and I've also copied over PR #135 code for the ts definitions of cookie-universal-nuxt. I've also published a new version of the package (v2.2.2). Let me know if ts definitions now works. Thanks for the PR!
@microcipcip Everything is working fine on my end using v2.2.2. Thank you!
Amazing!
I tried to write this line
const parsed = this.$cookies.nodeCookie.parse(cookies)
but getting errorProperty 'nodeCookie' does not exist on type 'NuxtCookies'
I check the definition type file and no nodeCookie property found? Does anyone know what I am doing wrong?