Skip to content

Is turbo in maintenance mode? #1456

@gtarsia

Description

@gtarsia

At the moment, there's 247 issues and 74 pull requests open. More than half of the issues that are older than a year have gone unreplied.

I've discovered as I dealt with a scroll to anchor bug, nothing serious, that I even got quickfix for (gently provided by @KonnorRogers).

From what I see this pull request might fix that bug:
#1285

And I saw a couple pull requests related that were closed by @brunoprietog saying "thank you, but we're using that pull request".

But that pull request was posted 15 months ago and it's still open.

Don't take this the wrong way. People work on open source for free 98% of the time. Thank you everyone who worked on this.
But I'm curious about the direction here, and maybe it helps to shed some light and bring some attention to this.

Turbo is an important piece in default Rails, and I feel worried that it might shed a bad light on the Rails experience.

Regards, Guido.


In case someone's interested about bug and the fix:
What's happening is that the anchor of the url is not respected when clicking anchors in the same page with scroll-behaviour: smooth and the page scrolls back to the top.

The fix is basically not scrolling in the preview, by including this in the HTML:

<head>
  <script>
    function scrollToHash () {
      if (document.documentElement.hasAttribute("data-turbo-preview")) {
        // Turbo Drive is displaying a preview, don't scroll?
        return
      }
  
      const hash = window.location.hash
      if (hash) {
        const el = document.querySelector(hash)
  
        if (el) { el.scrollIntoView() }
      }
    }
    document.addEventListener("turbo:render", scrollToHash)
  </script>
</head>

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions