YAML: JSON To Structurfield

Hello,

has someone possibly written a helper who converts a json into a structure field?

greetings
perry

You mean into structure items to store in a content file? Or to create structure field definitions for a blueprint?

You mean into structure items to store in a content file?

I have a large number of names / values in a JSON file, now I would like to save these in the content file (.txt) as a structure field in order to edit them later in the panel.

Try yq (GitHub - mikefarah/yq: yq is a portable command-line YAML processor) which is designed to convert JSON into YAML (and more).

You can convert your JSON to an array (PHP: json_decode - Manual) and then yaml encode it using Data::encode($array, 'yaml'). Then update the page with this data.

thank you for your help!
I made JSON2YAML with vscodium with find & replace.