chore: fix useShadowRoot warning method name

This commit is contained in:
Evan You 2024-08-07 17:21:36 +08:00
parent 6758c3cd04
commit 197afc2c1f
No known key found for this signature in database
GPG Key ID: 00E9AB7A6704CE0A
1 changed files with 2 additions and 2 deletions

View File

@ -664,10 +664,10 @@ export function useShadowRoot(): ShadowRoot | null {
return (el as VueElement).shadowRoot return (el as VueElement).shadowRoot
} else if (__DEV__) { } else if (__DEV__) {
if (!instance) { if (!instance) {
warn(`useCustomElementRoot called without an active component instance.`) warn(`useShadowRoot called without an active component instance.`)
} else { } else {
warn( warn(
`useCustomElementRoot can only be used in components defined via ` + `useShadowRoot can only be used in components defined via ` +
`defineCustomElement.`, `defineCustomElement.`,
) )
} }