Discuss and resolve questions on Liquid, JavaScript, themes, sales channels, and site speed enhancements.
i have created block of blog , that is input type=blog , how can i access blog object by looping blocks of blog
To access the blog object within a loop of blocks in your Liquid code, you can use the following syntax:
{% for block in section.blocks %}
{% assign blog = block.settings.blog %}
{{ blog | json }}
{% endfor %}
In the above code, the block.settings.blog
represents the blog object defined in each block's settings. By assigning it to the blog
variable, you can then use {{ blog | json }}
to output the JSON representation of the blog object.
Shopify and our financial partners regularly review and update verification requiremen...
By Jacqui Mar 14, 2025Unlock the potential of marketing on your business growth with Shopify Academy's late...
By Shopify Mar 12, 2025Learn how to increase conversion rates in every stage of the customer journey by enroll...
By Shopify Mar 5, 2025