paloma
paloma copied to clipboard
Does 'Turbolinks Support' section in the documentation require updating?
I was looking at the documentation about the forward/back button in the 'Turbolinks Support' and I was trying to ensure my code is executed in this same manner for my project. I added the following code (which was taken from the documentation) to my application js:
$(document).on('page:restore', function(){
// Manually evaluates the appended script tag.
Paloma.executeHook();
});
This would not work for me. I had to modify it as below:
$(document).on('page:restore', function(){
// Manually evaluates the appended script tag.
Paloma.executeHook();
Paloma.engine.start();
});
Is what I've done correct and the documentation just needs updating? Or have I missed something else?
This might be the case since Paloma.start()
is no longer called automatically and needs to always be explicitly called.