loading...

re: Vuex + TypeScript VIEW POST

TOP OF THREAD FULL DISCUSSION
re: Great post. I’m curious that everything you did is just TypeScript things except defining global $store type, so isn’t possible to do the same in V...
 

What we did in our project is that we just removed the global vuex types/vue.d.ts files, and used the approach with Vue 2.x. Take a look at npm-patch-package. Then you can just comment out these lines and apply the patch. That's it, you can type the store in 2.x.

I also like the idea that API and code stay the same, we just enhance typings.

Code of Conduct Report abuse