anish2690 / vue-cookie-next

A vue 3 plugin for handling browser cookies with typescript support. Load and save cookies within your Vue 3 application
MIT License
53 stars 6 forks source link

Vue 3 TypeScript Error: TypeError: Cannot read property 'isCookieAvailable' of undefined #7

Closed roberttolton closed 2 years ago

roberttolton commented 3 years ago

Regarding the following line:

https://github.com/anish2690/vue-cookie-next/blob/56a4da3bf0085ad7656659a70d13e82634e6756a/src/VueCookieNext.ts#L178

Using within an onMounted hook within the setup method, this is undefined.

tapanmodh commented 3 years ago

same issue. do we have any workaround for this?

roberttolton commented 3 years ago

@TapanM I just switched to https://github.com/js-cookie/js-cookie

anish2690 commented 2 years ago

@roberttolton @TapanM i think this should be already fixed, not able to reproduce it. If you still facing issue please post reproduction repo link.