Skip to content

Instantly share code, notes, and snippets.

@joe-dempsey
Last active October 18, 2021 15:53
Show Gist options
  • Save joe-dempsey/65f7ad4833a6154b691804736911c48d to your computer and use it in GitHub Desktop.
Save joe-dempsey/65f7ad4833a6154b691804736911c48d to your computer and use it in GitHub Desktop.
related-products.liquid for narrative theme
@longtiennguyen
Copy link

Thanks for sharing. But...

  1. all related products are shown though i set 4 per row and 2 row.
  2. how to set all related products at grid style (not collage style)?
    Thanks

@hankpalan
Copy link

Thanks for sharing. But...

  1. all related products are shown though i set 4 per row and 2 row.
  2. how to set all related products at grid style (not collage style)?
    Thanks

There was code missing from the original, place this back in around line 5 and you can pick and chose the per row settings:

{% assign number_of_related_products_per_row = section.settings.related_grid_num %}
{% assign number_of_rows = section.settings.related_grid_row %}

@StudioMon
Copy link

Hi :)

Thanks for sharing!

Can you please tell me how to have the related products based on a collection / tag?

I'm offering only one collection at a time (the rest of the collections are just for archive purposes), so I'm trying to have the navigation between items only within it.

Many Thanks!

@StudioMon
Copy link

And just another question: can I change / remove the limit number of the related products?

Thanks a lot!

@StudioMon
Copy link

StudioMon commented Mar 21, 2021

@hankpalan, maybe you can assist?

@levister-onyx
Copy link

Hi, after i apply the code, it is only reflecting on the editor mode but not showing on the storefront.
anyone help.
Narrative 10.5.0

@joe-dempsey
Copy link
Author

@levister-onyx
i don't think they won't render unless you have some sales

@levister-onyx
Copy link

hi @joe-dempsey
what you mean sales? if someone already bought on my store? the answer is yes. we have some sales already

@levister-onyx
i don't think they won't render unless you have some sales

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment