Skip to content
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鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix back-forth navigation delay #6035

Merged
merged 2 commits into from
Oct 3, 2022
Merged

Fix back-forth navigation delay #6035

merged 2 commits into from
Oct 3, 2022

Conversation

fregante
Copy link
Member

@fregante fregante commented Oct 2, 2022

Here's what I think happens:

  • Turbo caches the style elements by outerHTML
  • We alter the content of the style element
  • Turbo finds "a new style element" (same element, but different outerHTML)
  • No load/error events are fired because the element is the same

I assume this issue exists in every browser so it makes sense to use a fix that works in every browser. I haven't experienced it because I'm on the LTS version (Safari 馃ゲ)

@fregante
Copy link
Member Author

fregante commented Oct 2, 2022

@kaste @probablykasper

@fregante fregante added the bug label Oct 2, 2022
@kaste
Copy link

kaste commented Oct 2, 2022

Works for me.

Copy link

@mmelikyan mmelikyan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

much needed!!!

@fregante fregante changed the title Fix back-forth navigation delay caused by some features Fix back-forth navigation delay Oct 3, 2022
@fregante fregante merged commit d14e9d1 into main Oct 3, 2022
@fregante fregante deleted the ajax-fix branch October 3, 2022 06:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Development

Successfully merging this pull request may close these issues.

Back/forth navigation is delayed
3 participants