I have quite long JSON-LD schemas, and it would be very useful if we could support passing down space property down to JSON stringify.
Something like:
export class JsonLd<T extends Thing> extends React.Component<{
item: WithContext<T>;
space?: string | number;
}> {
render() {
return (
<script
type="application/ld+json"
dangerouslySetInnerHTML={{
__html: JSON.stringify(this.props.item, safeJsonLdReplacer, this.props.space)
}}
/>
);
}
}
I could do a PR with this