Conversation
|
Just what I needed. Hope this gets merged into the main repo. |
|
"The command "bundle exec rake" exited with 1." - So not my code problem |
|
Hello, this PR has compability only with the older Turbolinks version. Because you are listening "page:load" (the old way) instead of "turbolinks:load" (the current version). Check the Should I use Turbolinks 5 or Turbolinks Classic? section: |
Not so sure about that.. |
|
I am using Turbolinks 5 and I never had problems with the Intercom Widget ?? (Or maybe I had problems all along but I didn't notice :o ) EDIT : nvm, this is just for the first page load, but if you need to push data on every "turbolinked" page then I haven't tested. |
|
@Startouf may be because you load this widget on every page? |
Intercom is not configured to work with Turbolinks. This commit forces Intercom to reload it's messenger when a new page loads via the following line of code:
document.addEventListener('page:load', l, false)
This was inspired by the following PR:
intercom#215
I am testing this branch via Intercom's instructions:
https://github.com/intercom/intercom-rails#running-testsspecs
Majority of Rails applications use Turbolinks. So, it's helpful to support them