We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent df066c9 commit a610d56Copy full SHA for a610d56
src/app.ts
@@ -40,10 +40,14 @@ export const createApp = (initialData?: any) => {
40
}
41
42
el = el || document.documentElement
43
- let roots = el.hasAttribute('v-scope')
44
- ? [el]
45
- : // optimize whole page mounts: find all root-level v-scope
46
- [...el.querySelectorAll(`[v-scope]:not([v-scope] [v-scope])`)]
+ let roots: Element[]
+ if (el.hasAttribute('v-scope')) {
+ roots = [el]
+ } else {
47
+ roots = [...el.querySelectorAll(`[v-scope]`)].filter(
48
+ (root) => !root.matches(`[v-scope] [v-scope]`)
49
+ )
50
+ }
51
if (!roots.length) {
52
roots = [el]
53
0 commit comments