klaro-js
klaro-js copied to clipboard
Do not remove ID attribute from SCRIPT tags
When Klaro rewrites script tags of the third-party apps/trackers, it removes id attribute if it is present in the script tag. It causes problems with some apps, for example Zendesk Widget. The tag below
<script id="ze-snippet" type="text/plain" data-type="application/javascript" data-src="https://static.zdassets.com/ekr/snippet.js?key=***" data-name="zendesk"></script>
is being rewritten to:
<script type="text/javascript" src="https://static.zdassets.com/ekr/snippet.js?key=***"></script>
...and stops working, because of the missing id attribute. Is it possible to change this behavior?