docs: mention .global.vue filename for global components (#25144)

This commit is contained in:
chris-basebone 2024-01-16 13:21:49 +02:00 committed by GitHub
parent e166b6e648
commit f310dd1e2d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -93,7 +93,7 @@ Alternatively, though not recommended, you can register all your components glob
})
```
You can also selectively register some components globally by placing them in a `~/components/global` directory.
You can also selectively register some components globally by placing them in a `~/components/global` directory, or by using a `.global.vue` suffix in the filename. As noted above, each global component is rendered in a separate chunk, so be careful not to overuse this feature.
::callout
The `global` option can also be set per component directory.