2
0
mirror of https://github.com/tenrok/vue-meta.git synced 2026-06-18 09:30:34 +03:00

docs: adds documentation for json option (#482)

* feat(Doc): adds json special tag info

* feat(Doc): fixes typo

* feat(Doc): removes unsafe example

* feat(Doc): fixes typo
This commit is contained in:
Marcel Pfeifer
2019-10-30 12:59:09 +01:00
committed by Pim
parent fa12530b3e
commit 0145166b08
+19
View File
@@ -641,6 +641,25 @@ When a metaInfo property has a `skip` attribute with truthy value it will not be
}
```
### json <Badge text="v2.1+"/>
The `json` attribute in a metaInfo property allows you to render JSON content within a script tag, while still sanitizing the keys and values. For example this can be used to render JSON-LD.
```js
{
metaInfo: {
script: [{
type: 'application/ld+json',
json: {
'@context': 'http://schema.org',
'@type': 'Organization',
name: 'NuxtJS'
}
}]
}
}
```
### body
### pbody <Badge text="v2.1+"/>