-
Notifications
You must be signed in to change notification settings - Fork 430
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Replacement for data-turbolinks-permanent? #21
Comments
@danjac Turbo has |
One thing I've noticed with data-turbo-permanent vs data-turbolinks-permanent: while the HTML itself is preserved, there appears to be an issue with elements inside the data-turbo-permanent element (at least in Chromium browsers). Page transitions seem to cause a reset, reloading the element, so if for example the audio is playing it will restart. This was not an issue in Turbolinks 5. |
Re audio: this appears to be similar to older Turbolinks issue here. Looks like workaround is to create the Audio element in Javascript rather than in the HTML (i.e. const audio = new Audio(...)) inside e.g. your Stimulus controller: |
|
Is there an open issue for this? |
What is the best practice for upgrading from Turbolinks 5 regarding the turbolinks-permanent directive? In this particular case, I use this to keep a video or audio component running between page transitions, without having the media element restart. The new turbo-frame does not seem to do the same thing. Has this been removed from the new Turbo? What's the best practice here?
The text was updated successfully, but these errors were encountered: