Document `useStore()`

Signed-off-by: Phillip Rak <rak.phillip@gmail.com>
This commit is contained in:
Phillip Rak 2024-04-12 12:52:32 -07:00
parent 6940a250b8
commit f2bf53015a
1 changed files with 6 additions and 0 deletions

View File

@ -1,5 +1,11 @@
import { getCurrentInstance } from 'vue';
/**
* useStore allows for accessing Vuex stores from within a setup function. This is a temporary measure for working with
* Vuex in Vue2.
*
* TODO: #9541 Remove for Vue 3 migration
*/
export const useStore = ():unknown => {
const vm = getCurrentInstance();