schema-dts icon indicating copy to clipboard operation
schema-dts copied to clipboard

Increasing HTML size

Open musen34 opened this issue 2 years ago • 1 comments

Hello,

I have 480 currency items and when I use schema-dts its increasing HTML size, how can I set export async like .json-ld file? I can success it with PHP, now I want to use for my NextJS project with this npm package.

musen34 avatar Mar 25 '22 08:03 musen34

This package only provides typings to be able to construct the right JSON as a plain JS object that you can then stringify and serve however you like.

If you're worried about Google Search only, Google does support dynamically inserting JSON-LD in a script just as you described (source). But this might not work for other consumers of the structured data.

Eyas avatar Mar 25 '22 21:03 Eyas