Need help with json LD code for list.single_line_text_field in Liquid?

Hi
I would like to write json ld code and I have a problem with list.single_line_text_field.
Maybe someone can help me:

I want to use this code in Liquid:

“recipeIngredient”: [
"ingredient 1“,
"ingredient 2“,
“ingredient 3”,
“ingredient 4”,
“ingredient 5”
],

So far so easy. With the normal singleline text metafield I would have solved it like this:

“recipeIngredient”: [
“{{ article.metafields.custom.ingredient_1 }}”,
“{{ article.metafields.custom.ingredient_2 }}”,
"{{ article.metafields.custom.ingredient_3 }}“,
“{{ article.metafields.custom.ingredient_4 }}”,
“{{ article.metafields.custom.ingredient_5 }}”,
],

But now I want to use the new List function.

Unfortunately I can’t find much online about it. How can I write the code that is then output like this. (Encapsulated in “” and comma after each value)

The only thing I found is “| metafield_tag” ​​which only outputs a

    .

    Unfortunately, I can’t program myself, but I can do html and css. So please a little more explanation would be nice :slightly_smiling_face:

    Thank you in advance for your help.

    Lea

1 Like