Skip to content

Commit 336a686

Browse files
authored
Make root refs available
1 parent 2560512 commit 336a686

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

resources/js/package.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -135,8 +135,9 @@ function init() {
135135
},
136136
},
137137
mounted() {
138+
window.app.config.globalProperties.refs = this.$refs
138139
setTimeout(() => {
139-
const event = new CustomEvent('vue:mounted', { detail: { vue: window.app } })
140+
const event = new CustomEvent('vue:mounted', { detail: { vue: window.app, rootNode: this } })
140141
document.dispatchEvent(event)
141142
})
142143
},
@@ -148,6 +149,7 @@ function init() {
148149
window.app.config.globalProperties = {
149150
custom: {},
150151
config: window.config,
152+
refs: {},
151153
loadingCount: fetchCount,
152154
loading: false,
153155
autocompleteFacadeQuery: '',

0 commit comments

Comments
 (0)