Shopify / product-reviews-sample-app

A sample Shopify application that creates and stores product reviews for a store, written in Node.js
MIT License
355 stars 158 forks source link

How to show review stars within collection templates? #1

Open atomgiant opened 3 years ago

atomgiant commented 3 years ago

I'd like to start a discussion about how to show the review stars for this sample app inside of a collection or search template.

For example, for each product in the collection, I'd like to see the average rating stars when viewing a collection or search template.

This use case doesn't seem to be directly supported with the new App Blocks unless I am mistaken. Do you have any tips you can share about how you might make this work?

Thanks, Tom

govindrai commented 3 years ago

Wondering the same. Did you have any luck figuring this out @atomgiant?

atomgiant commented 2 years ago

I don't believe OS2.0 supports this use case so there is no simple option that is OS2.0 native.

I decided to wait until after the holidays to decide which path to take to add app blocks to collection items.

I believe there are really only 2 options for this:

The App Embed block would be a very brittle process and need to change for each theme. So based on this, I'm leaning towards just using the Manual snippet option for collection items, and App blocks for product pages.

IMO this is a glaring flaw with OS2.0 so I hope they'll add some form of support in the future.