next-seo
next-seo copied to clipboard
Is it possible to add custom LD objects ?
I see some fields are not supported by the lib.
Is it possible to add custom LD data objects, that will not be validated by the lib?
I can take a look at this. Could you give me an example to work with?
For instance I want to add a graph with multiple products:
{
"@context": "http://schema.org",
"@graph": [
{
"@type": "Product",
"name": "tshirt",
"description": "test copy 1.",
"image": "image.jpg"
},
{
"@type": "Product",
"name": "tshirt 2",
"description": "test copy 2.",
"image": "image2.jpg"
}
]
}
Or when I am missing the GTIN or MPN google throws a warning. I could omit the warning by setting identifier_exists: false which seems not to be supported by this lib.
Basically this request is made to be able to tweak LData when this library cannot process it by default.
EDIT: identifier_exists: false seems also not being supported by google as well (although they have it in docs)
Also I would like to add multiple offers in EUR and in USD for example ...
I'm trying to add sitelinks search box, see: https://developers.google.com/search/docs/data-types/sitelinks-searchbox#example, up ❤️
@garmeeh +1 for this feature. Because this library doesn't support every Schema option, and because Schema could also change, it would be nice to have an escape hatch of sorts.
Something like —
<LogoJsonLd
logo="http://www.your-site.com/images/logo.jpg"
url="http://www.your-site.com"
custom={{
alt: 'Your site logo'
}}
/>
Assuming alt is a Schema object that isn't currently supported by LogoJsonLd. Everything in custom will be passed on to the JSON+LD object as-is.
+1 for the feature
very good proposition, +1 too
+1 for this feature. There will always be different versions of schemas, so custom ones should be possible. I.e. WebPageJsonLd could have name & primaryImageOfPage
strongly requesting this feature. The LD structure is changing time to time but this lib could not catch up