All things Shopify and commerce
We're moving the community! Starting July 7, the current community will be read-only for approx. 2 weeks. You can browse content, but posting will be temporarily unavailable. Learn more
hello I want to add script from my custom app to the view page of my website but it also show me in customization section i don't want it please help me https://prnt.sc/nT4WFyz012HS i don't want alert box here : https://prnt.sc/sDiyfLDrI8ou i only want it in website view section only
Solved! Go to the solution
This is an accepted solution.
{% if request.design_mode %}
{% else %}
<script>
alert ("home page");
</script>
{% endif %}
I found the solution after some research you just need to ad this conditional statement to remove scripts from customization of designing part
This is an accepted solution.
{% if request.design_mode %}
{% else %}
<script>
alert ("home page");
</script>
{% endif %}
I found the solution after some research you just need to ad this conditional statement to remove scripts from customization of designing part