Skip to content

[WebProfilerBundle] Disable Turbo for debug toolbar links #49226

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

Merged
merged 1 commit into from
Feb 4, 2023

Conversation

javiereguiluz
Copy link
Member

Q A
Branch? 5.4
Bug fix? yes
New feature? no
Deprecations? no
Tickets -
License MIT
Doc PR -

@stof suggested this change to me. I think it makes sense to merge it in 5.4 as a bug fix because otherwise, Symfony UX Turbo could mess with the links of the Web Debug Toolbar.

Copy link
Member

@stof stof left a comment

Choose a reason for hiding this comment

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

We already disable Turbolink since years (for the same reason: making sure the WebProfiler pages are always loaded through a full page load to avoid conflicts with project code). and with Symfony UX supporting Turbo, it makes sense to make it work smoothly here.

@fabpot
Copy link
Member

fabpot commented Feb 4, 2023

Thank you @javiereguiluz.

@fabpot fabpot merged commit 9a11bbd into symfony:5.4 Feb 4, 2023
@javiereguiluz javiereguiluz deleted the toolbar_turbo branch February 4, 2023 08:35
This was referenced Feb 28, 2023
nicolas-grekas added a commit that referenced this pull request Feb 20, 2024
…to avoid link prefetching (davidgorges)

This PR was merged into the 5.4 branch.

Discussion
----------

[WebProfilerBundle] disable turbo in web profiler toolbar to avoid link prefetching

| Q             | A
| ------------- | ---
| Branch?       | 5.4
| Bug fix?      | yes
| New feature?  | no
| Deprecations? | no
| Issues        | [symfony/ux#1520](symfony/ux#1520)
| License       | MIT

This adds `data-turbo="false"` to the web profiler toolbar html. It [has been added already a while ago](#49226) to the mini-toolbar, and there is already the old `data-no-turbolink` attribute present.

This [fixes an issue](symfony/ux#1520) with prefetching links in Turbo 8, which causes the Ajax pane to behave weirdly and can even cause unwanted logouts (via the logout link inside the security pane).

Commits
-------

9750a6b [WebProfilerBundle] disable turbo in web profiler toolbar to avoid link prefetching
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants