Skip to content

Commit a4cf142

Browse files
committed
add custom block examples
1 parent 4573adc commit a4cf142

File tree

1 file changed

+8
-2
lines changed

1 file changed

+8
-2
lines changed

src/api/sfc-spec.md

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ export default {
4040

4141
### `<script>`
4242

43-
- Each `*.vue` file can contain at most one `<script>` block at a time (excluding [<script setup>](/api/sfc-script-setup.html)).
43+
- Each `*.vue` file can contain at most one `<script>` block at a time (excluding [`<script setup>`](/api/sfc-script-setup.html)).
4444

4545
- The script is executed as an ES Module.
4646

@@ -60,7 +60,13 @@ export default {
6060

6161
### Custom Blocks
6262

63-
Additional custom blocks can be included in a `*.vue` file for any project specific needs, for example a `<docs>` block. Handling of Custom Blocks will depend on tooling - see [SFC Tooling](/api/sfc-tooling#custom-blocks-integration) for more details.
63+
Additional custom blocks can be included in a `*.vue` file for any project specific needs, for example a `<docs>` block. Some real-world examples of custom blocks include:
64+
65+
- [Gridsome: `<page-query>`](https://gridsome.org/docs/querying-data/)
66+
- [vite-plguin-vue-gql: `<gql>`](https://github.com/wheatjs/vite-plugin-vue-gql)
67+
- [vue-i18n: `<i18n>`](https://github.com/intlify/bundle-tools/tree/main/packages/vite-plugin-vue-i18n#i18n-custom-block)
68+
69+
Handling of Custom Blocks will depend on tooling - if you want to build your own custom block integrations, see [SFC Tooling](/api/sfc-tooling#custom-blocks-integration) for more details.
6470

6571
## Automatic `name` Inference
6672

0 commit comments

Comments
 (0)