Module: Spree::TurboHelper
- Defined in:
- app/helpers/spree/turbo_helper.rb
Instance Method Summary collapse
Instance Method Details
#spree_turbo_update_cart(order = current_order) ⇒ Object
9 10 11 |
# File 'app/helpers/spree/turbo_helper.rb', line 9 def spree_turbo_update_cart(order = current_order) turbo_stream.update_all '.cart-counter', order.item_count.positive? ? order.item_count : '' end |
#spree_turbo_update_flashes ⇒ Object
3 4 5 6 7 |
# File 'app/helpers/spree/turbo_helper.rb', line 3 def spree_turbo_update_flashes turbo_stream.update 'flash' do render 'spree/shared/flashes' end end |