Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@ data_sources:
# The type is the identifier of the data source. By default, this will be
# `filesystem_unified`.
type: filesystem_unified
encoding: utf-8

# The path where items should be mounted (comparable to mount points in
# Unix-like systems). This is “/” by default, meaning that items will have
Expand Down
29 changes: 29 additions & 0 deletions content/libraries/jivochat.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
---
title: JivoChat
contributors:
- user: jfloff
name: Joao Ferreira Loff
---

# JivoChat

> **[jivochat.com](http://jivochat.com/)**

I had problems with JivoChat when changing pages, which has been reported by [others](https://stackoverflow.com/questions/39273134/turbolinks-and-3d-party-plugins-issue).

### Official Implementation
After creating and customizing a widget, you will be give an embed code similar to this:

```html
<!-- BEGIN JIVOSITE CODE {literal} -->
<script type='text/javascript'>
(function(){ var widget_id = 'JIVOCHAT_ID';var d=document;var w=window;function l(){
var s = document.createElement('script'); s.type = 'text/javascript'; s.async = true; s.src = '//code.jivosite.com/script/widget/'+widget_id; var ss = document.getElementsByTagName('script')[0]; ss.parentNode.insertBefore(s, ss);}if(d.readyState=='complete'){l();}else{if(w.attachEvent){w.attachEvent('onload',l);}else{w.addEventListener('load',l,false);}}})();</script>
<!-- {/literal} END JIVOSITE CODE -->
```

### Solution
Just add the following code `s.setAttribute('data-turbolinks-track', 'reload');` in between existing code, like this:
<pre><code>
s.type = 'text/javascript'; <b>s.setAttribute('data-turbolinks-track', 'reload');</b> s.async = true;
</code></pre>