1
0
Эх сурвалжийг харах

feat(cientos): getting app from getCurrentInstance 🤩

Alvaro 2 жил өмнө
parent
commit
f899977f25

+ 3 - 1
packages/cientos/src/core/useCientos.ts

@@ -1,7 +1,9 @@
 import { useCatalogue } from '@tresjs/core'
+import { getCurrentInstance } from 'vue'
 
 export function useCientos() {
-  const { catalogue, extend } = useCatalogue(window.__TRES__.app)
+  const { appContext } = getCurrentInstance()
+  const { catalogue, extend } = useCatalogue(appContext.app)
 
   return {
     catalogue,