parse_json filter will convert a string into JSON object.
parse_json
{% capture order %} { "id": "531341221233", "name": "RF412", "customer": { "first_name": "Adam", "last_name": "Smith" } } {% endcapture $} {% assign order = order | parse %} {{ "Order name is" | append: order["name"] | log }}
Last updated 8 months ago