Commit f67213736fb2ec7f6f948a8512eae808eea8ba90

Authored by Antoine Goutenoir
1 parent ac935afa
Exists in master

Add the tawk.to widget.

/spent 2h
flaskr/templates/base.html
... ... @@ -96,6 +96,10 @@
96 96 </div>
97 97 </footer>
98 98  
  99 + {% block tawk %}
  100 + {% include "partial/tawk-to-widget.html" %}
  101 + {% endblock %}
  102 +
99 103 {% assets "common_js" %}
100 104 <script type="text/javascript" src="{{ ASSET_URL }}"></script>
101 105 {% endassets %}
... ...
flaskr/templates/partial/tawk-to-widget.html 0 → 100644
... ... @@ -0,0 +1,14 @@
  1 +
  2 +{# Chat widget for tawk.to #}
  3 +<script type="text/javascript">
  4 +var Tawk_API=Tawk_API||{}, Tawk_LoadStart=new Date();
  5 +(function(){
  6 +var s1=document.createElement("script");
  7 +var s0=document.getElementsByTagName("script")[0];
  8 +s1.async=true;
  9 +s1.src='https://embed.tawk.to/5e4a9b00a89cda5a188669a4/default';
  10 +s1.charset='UTF-8';
  11 +s1.setAttribute('crossorigin','*');
  12 +s0.parentNode.insertBefore(s1,s0);
  13 +})();
  14 +</script>
... ...