protonemedia/laravel-splade

How to preserve fragment url when navigating from another route?

adin00 opened this issue · 1 comments

  • Laravel Version: 9.52.7
  • PHP Version: 8.2.3
  • Splade JS Version (npm): 1.4.8
  • Splade PHP Version (composer): 1.4.8
  • Dev environment (OS, Sail/Valet/etc): MacOS + Sail

Description:

For example:

      <Link href="{{ route('some.route') }}#section-3">
        Go to Section 3
      </Link>

The above code deletes the fragment at the end.
The only workaround I could find is using the <a> tag instead, with the downside of a full page reload.

Fixed in v1.4.9. Make sure to update both packages (JS + PHP).