Module: Spree::StructuredDataHelper
- Defined in:
- app/helpers/spree/structured_data_helper.rb
Instance Method Summary collapse
Instance Method Details
#products_structured_data(products) ⇒ Object
3 4 5 6 7 8 9 10 11 |
# File 'app/helpers/spree/structured_data_helper.rb', line 3 def products_structured_data(products) content_tag :script, type: 'application/ld+json' do raw( products.map do |product| structured_product_hash(product) end.to_json ) end end |