JSFiddle - React, Tailwind, and code Playground

by karlhorky

HTML

<div id="squatchembed" style="width:500px">Loading your widget preview...</div>
<script type="text/javascript">
        var _sqh = _sqh || [];

            // Push user details for the user who is logged in to your SaaS app
            _sqh.push(['init', {
                tenant_alias: 'test_abifhtnn61vd3',
                account_id: 'cus_12abc',
                user_id: '1234',
                email: '[email protected]',
                first_name: 'Demo',
                last_name: 'Tester',
                mode: "DEMO_EMBED"
            }]);

            //Autofill connects referral coupons to your payment form
            _sqh.push(['autofill', '#my_coupon']);

            // Include squatch.js
            (function(){function l(){var s=document.createElement("script");s.type="text/javascript";s.async=true;s.src=location.protocol+"//app.referralsaasquatch.com/assets/javascripts/squatch.min.js";var t=document.getElementsByTagName("script")[0];t.parentNode.insertBefore(s,t)}if(window.attachEvent){window.attachEvent("onload",l)}else{window.addEventListener("load",l,false)}})();
</script>