Skip to content

Allow app blocks between article sections#52

Open
patrickbolle wants to merge 1 commit intoShopify:mainfrom
patrickbolle:article-app-blocks-between-sections
Open

Allow app blocks between article sections#52
patrickbolle wants to merge 1 commit intoShopify:mainfrom
patrickbolle:article-app-blocks-between-sections

Conversation

@patrickbolle
Copy link

@patrickbolle patrickbolle commented Feb 24, 2026

Problem

App blocks on the article page are forced to render below all article content. Unlike the product page where merchants can place app blocks between sections like title and price, the article page pins its blocks to fixed positions using static content_for 'block' calls, with content_for 'blocks' only at the bottom.

This is extremely limiting for apps that interact with blog post templates (eg. my app, Recipe Kit). Our team spends hours every week working with merchants to simply place their recipe card in a good looking spot on the Horizon theme - but this fix will resolve that for us and all the other blog post apps.

Solution

Switch the article section to use content_for 'blocks' (the same pattern used by _product-details) so all blocks render in the order merchants arrange them in the theme editor.

Changes:

  • Replace pinned content_for 'block' calls with content_for 'blocks' in main-blog-post.liquid
  • Remove static: true from article template blocks and add block_order to preserve default ordering
  • Add _blog-post-* types to the section schema (required once blocks are no longer static)
  • Move the image nil guard into _blog-post-featured-image.liquid since the block is now self-contained

Currently, app blocks on the article page are forced to render below
all article content. Unlike the product page where app blocks can be
placed between sections (e.g. between title and price), the article
page pins its blocks to fixed positions using static content_for calls.

This changes the article section to use content_for 'blocks' so that
all blocks — including app blocks — render in the order merchants
arrange them in the theme editor.

Changes:
- Replace pinned content_for 'block' calls with content_for 'blocks'
- Remove static: true from article template blocks
- Add block_order to preserve default ordering
- Add _blog-post-* types to section schema (required for non-static)
- Move image nil guard into _blog-post-featured-image block itself
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant