Skip to content

Conversation

@jcoyne
Copy link
Member

@jcoyne jcoyne commented Oct 10, 2024

No description provided.

@jrochkind
Copy link
Member

jrochkind commented Oct 10, 2024

I don't understand this stuff, so believe you that we don't need it anymore and love to see it go.

Can any of these conditional event names also be removed, are any of them for old turbolinks stuff no longer needed to support? (In my head since I was just looking at them to debug the mystifying problem we were talking about in slack)

if (typeof Turbo !== 'undefined') {
listeners.push('turbo:load', 'turbo:frame-load');
} else if (typeof Turbolinks !== 'undefined' && Turbolinks.supported) {
// Turbolinks 5
if (Turbolinks.BrowserAdapter) {
listeners.push('turbolinks:load');
} else {
// Turbolinks < 5
listeners.push('page:load', 'DOMContentLoaded');
}
} else {

<% end %>

<% content_for(:skip_links) do -%>
<%= link_to t('blacklight.skip_links.first_result'), '#documents', class: 'd-inline-flex p-2 m-1', data: { turbolinks: 'false' } %>
Copy link
Member

Choose a reason for hiding this comment

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

shouldn't this be data: { turbo: false }?

Copy link
Member Author

Choose a reason for hiding this comment

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

I don't think that turbo needs to skip this. I'm pretty sure it knows that intra-document links don't get cached.

@jcoyne jcoyne force-pushed the remove-turbolinks branch from a309280 to 4be68b0 Compare October 22, 2024 03:58
@jcoyne jcoyne merged commit 38d96ef into main Oct 24, 2024
13 checks passed
@jcoyne jcoyne deleted the remove-turbolinks branch October 24, 2024 12:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants