vuejs / vuex

🗃️ Centralized State Management for Vue.js.
https://vuex.vuejs.org
MIT License
28.41k stars 9.58k forks source link

TypeError: Cannot read properties of undefined (reading '$store') #2239

Open nhrmart opened 11 months ago

nhrmart commented 11 months ago

Version

4.0.0

Describe the bug

I am using the latest vue js version and 4.0.0 vuex, my project is typescript based, and the components are based on composition API, using VS Code, no errors during development, no errors when running npm run serve, and also none during build process, but when i use the build files to browser the app in browser, then i am getting this error

Reproduction

I don't know

Expected behavior

code should run smoothly since there was no issue during development

Additional context

No response

Validations