Skip to content

Commit 5a4e187

Browse files
committed
add browser config example for custom element check
1 parent f9e2868 commit 5a4e187

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

src/guide/web-components.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,14 @@ By default, Vue will attempt to resolve a non-native HTML tag as a registered Vu
1414

1515
If you are using Vue with a build setup, the option should be passed via build configs since it is a compile-time option.
1616

17+
#### Example In-Browser Config
18+
19+
```js
20+
// Only works if using in-browser compilation.
21+
// If using build tools, see config examples below.
22+
app.config.compilerOptions.isCustomElement = tag => tag.includes('-')
23+
```
24+
1725
#### Example Vite Config
1826

1927
```js

0 commit comments

Comments
 (0)