Skip to content

Commit

Permalink
⚡ [api] use API-Store of top frame
Browse files Browse the repository at this point in the history
  • Loading branch information
jxn-30 committed Mar 11, 2024
1 parent 613f5f1 commit a5347ac
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/stores/api.ts
Original file line number Diff line number Diff line change
Expand Up @@ -849,4 +849,6 @@ export const defineAPIStore = defineStore('api', () => {
});

export const useAPIStore: () => ReturnType<typeof defineAPIStore> = () =>
(window[PREFIX] as Vue)?.$stores?.api ?? defineAPIStore();
(window.top?.[PREFIX] as Vue)?.$stores?.api ??
(window[PREFIX] as Vue)?.$stores?.api ??
defineAPIStore();

0 comments on commit a5347ac

Please sign in to comment.