How to use the same section settings across different templates?

Hello,

I’m building a store with an infinite product scroll and AJAX filtering on a homepage. Besides products, the rendered array contains a bunch of question cards, concatenated with a product array. The mentioned cards are to be created/edited by shop administrator via blocks. To allow AJAX filtering by product type, I’m sending a httpRequest to ‘/collections/types?q=selected product types’ with the collection page containing the same products+cards section as the homepage, but in order to get the desired result shop administrator has to manually duplicate all the blocks from the homepage, which seems quite inconvenient.

Is there any way I can use the same section settings across several templates, namely, Homepage and Collection with no need to create same blocks separately for those two templates?

@philippe_p

yes your try global template

https://www.shopify.com/partners/blog/shopify-online-store

You mean settings schema? That won’t work here because it doesn’t support blocks. They can only be used in sections.

Anyway, came up with a workaround, moving question cards to collection and loading them on a homepage via AJAX call, but if there’s a nicer, Liquid-only solution, would be great to know it.

@philippe_p

customization code possible to all new changes