This fix addresses Wyng campaigns conflicting with es6-collections.js in Magento

In Magento 2 an ES6 called polyfill es6-collections.js causes a conflict and throws an error of "Out of stack space".


Solution 1 - Removal

The most simple solution to this issue is to remove the use of es6-collections.js.  At the time of writing IE11 usage is below 11% and declining. The polyfill is mostly required for earlier versions of IE and from our limited testing, we have seen no adverse effect of removing es-collections.js in the themes we have tested. We would advise testing thoroughly.


Solution 2 - Postscript Message to bypass the conflict


nb. It is important to follow the steps in this order. 
If your sidebar is blank and does not look like our screenshots you need to remove the code in step X temporarily whilst you make edits.

  1.  Login into your Wyng Dashboard and open the campaign.
  2. Click Settings in the side bar
  3. Expand the Custom javascript box
  4. Right click on the word JavaScript
  5. Click on the row show in the image
  6. On the right-hand side in the styles tab Uncheck the box next to the style
  7. Collapse and expand the Custom JavaScript box. When you reopen it a new box will appear below. Paste the following into the box as shown in the image.

    https://s3.amazonaws.com/wyng/themes/postmessage/postmessage.iframe.js




  8. Now click on Layout. Add an HTML box to anywhere in your design. Right at the top or bottom is best. Add the following code into the HTML block as shown in the image below.

    <style>
    html.wf-anton-n4-active, html.wf-anton-n4-active body {
    height:auto!important}
    </script>



  9. The sidebar contents will possibly disappear now. And look like the image below. If you need to use the sidebar just remove the HTML added in step 8 and re-add it when you have finished making your edits.

  10. Publish your campaign so the changes take effect.
  11. The final step is to replace the code on your site.  If you are adding the campaign to a CMS page simply past the code below into your content section and replace {{campaign-id}} with the ID of the campaign you have added the postscript JS in to.

    <script type="text/javascript" src="https://s3-eu-west-1.amazonaws.com/pro-serv-london/core/postmessage/1.0.4/postmessage.parent.js"></script> 
    <div class="wyng-iframe" data-link="https://experiences.wyng.com/campaign/?experience={{campaign-id}}"></div> 



  12. Check your campaign is showing up in IE11.