{% sw_extends '@Storefront/storefront/base.html.twig' %} {# ── Sticky Add to Cart Bar mount point ─────────────────────────────────── base_body_script is the last block before on EVERY storefront page, regardless of page type or CMS layout — the only reliably universal hook available since Shopware's product detail page has no dedicated template of its own anymore (it's rendered through CMS blocks; see ProductStickyCartSubscriber's docblock). The presence check below means this only ever renders real markup on product pages where the merchant has the feature enabled; everywhere else this block is a silent no-op. "with { page: page } only" passes ONLY the page variable into the included component template's isolated context — matches what sticky-cart-bar.html.twig expects (page.extensions.sellopsStickyCart / page.product). #} {% block base_body_script %} {{ parent() }} {% if page is defined and page.extensions is defined and page.extensions.sellopsStickyCart is defined %} {% include '@SellopsStickyCart/storefront/component/sticky-cart/sticky-cart-bar.html.twig' with { page: page } only %} {% endif %} {% endblock %}