Live Updates Troubleshooting
Written By Luke Wakefield
Last updated About 2 months ago
1) Live updates automatically strips out <script> tags from updated HTML, for security and performance reasons. This can cause problematic behaviour on Product List views with add to cart buttons on each item.
To solve this, you can add the following code manually on the top of the wrapper or page:
<script>window.s_csrf_token = "{{context.authenticity_token}}";</script>
<script async src="{{ 'modules/siteglide_ecommerce/js/siteglide_ecommerce.js' | asset_url }}"></script>Was this helpful?
More in Live Updates JavaScript API
Introducing the Live Updates APILive Updates ChangelogAdding Live Updates to a dynamic sectionLive Updates Markup ExampleStill need help? Ask the team