Untitled

 avatar
unknown
plain_text
a month ago
1.2 kB
3
No Index
<script type="text/javascript"> 
(function() {
    function asyncLoad() {
        var urls = ["https://shopify.shopthelook.app/shopthelook.js?shop=myfashionbranddemo.myshopify.com&widget=1&mainProductId={{section.settings.postId}}&definedTemplate=inpage_r""];
        for (var i = 0; i < urls.length; i++) {
            var s = document.createElement('script');
            s.type = 'text/javascript';
            s.async = true;
            s.src = urls[i];
            var x = document.getElementsByTagName('script')[0];
            x.parentNode.insertBefore(s, x);
        }
    };
    if(window.attachEvent) {
        window.attachEvent('onload', asyncLoad);
    } else {
        window.addEventListener('load', asyncLoad, false);
    }
})();
</script>
<div class="ShopTheLook-section" data-product-id="{{section.settings.postId}}"></div>
{% schema %}
    {
        "name": "Shop The Look",
        "settings": [
            {
            "id": "postId",
            "type": "text",
            "label": "Add Look ID",
            "default": "123456" 
            }
        ],
        "presets": [{
            "name": "Shop The Look Section",
            "category": "ShopTheLook"
        }]
    }
{% endschema %}
Editor is loading...
Leave a Comment