[openstreetmap/openstreetmap-website] Don't do partial renders for turbo page visits (PR #6187)

Tom Hughes notifications at github.com
Sat Jul 12 14:36:02 UTC 2025


Setting `turbo-action=advance` as our pagination helper does causes a frame navigation to be [promoted to a page visit](https://turbo.hotwired.dev/handbook/frames#promoting-a-frame-navigation-to-a-page-visit) which means turbo will try and [merge the head elements](https://turbo.hotwired.dev/handbook/drive#page-navigation-basics) and remove meta and link elements which are missing from the turbo response.

In order to avoid breaking things we need to ensure we send the full head element in such cases or things like the CSRF token will be lost.

Fixes #6172
You can view, comment on, or merge this pull request online at:

  https://github.com/openstreetmap/openstreetmap-website/pull/6187

-- Commit Summary --

  * Don't do partial renders for turbo page visits

-- File Changes --

    M app/controllers/diary_entries_controller.rb (2)
    M app/controllers/issues_controller.rb (2)
    M app/controllers/traces_controller.rb (2)
    M app/controllers/user_blocks_controller.rb (2)
    M app/controllers/users/diary_comments_controller.rb (2)
    M app/controllers/users/issued_blocks_controller.rb (2)
    M app/controllers/users/lists_controller.rb (2)
    M app/controllers/users/received_blocks_controller.rb (2)

-- Patch Links --

https://github.com/openstreetmap/openstreetmap-website/pull/6187.patch
https://github.com/openstreetmap/openstreetmap-website/pull/6187.diff

-- 
Reply to this email directly or view it on GitHub:
https://github.com/openstreetmap/openstreetmap-website/pull/6187
You are receiving this because you are subscribed to this thread.

Message ID: <openstreetmap/openstreetmap-website/pull/6187 at github.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstreetmap.org/pipermail/rails-dev/attachments/20250712/b1e015df/attachment.htm>


More information about the rails-dev mailing list