Should string values within JSON-LD content be escaped? For instance, Google recommends the following to provide hints for sitesearch:
<script type="application/ld+json">
{
"@context": "http://schema.org",
"@type": "WebSite",
"url": "https://www.example-petstore.com/",
"potentialAction": {
"@type": "SearchAction",
"target": "https://query.example-petstore.com/search?q={search_term_string}",
"query-input": "required name=search_term_string"
}
}
</script>
But what if my site's search URL contains multiple query parameters? Should, or can, characters within the value for target be escaped? For instance:
"target": "https://query.example-petstore.com/search?foo=bar\u0026q={search_term_string}",
The same question applies to several common schema.org types when marking up in JSON-LD. Google+ social profile links in Organization->sameAs for example: If my organization's profile is
https://plus.google.com/+BeardsAreSweet
should that be represented as:
"sameAs": ["https://plus.google.com/+BeardsAreSweet"]
or
"sameAs": ["https://plus.google.com/\u002bBeardsAreSweet"]
More importantly, does it matter at all?