I'm not sure if this is in the documentation but, you can use Jinja's "raw" blocks. Here's a test for you. You will see the console output is "hello" so, it successfully replaced the string "{{width}}"
<script>
{% raw %}
var e = "{{width}}";
console.log(e.replace(/{{(width|height)}}/g,"hello"));
{% endraw %}
</script>
If this answer helped, please, mark as solved 😄
tim@belch.io | forms.belch.io | Design your own Beautiful HubSpot Forms; No coding necessary.