Skip to content

Query params trigger the trailingSlash error in preview mode #8942

@kamoshi

Description

@kamoshi

Astro Info

Astro                    v3.4.0
Node                     v20.9.0
System                   Linux (x64)
Package Manager          pnpm
Output                   static
Adapter                  none
Integrations             @astrojs/mdx
                         @astrojs/solid-js
                         pagefind

If this issue only occurs in one browser, which browser is a problem?

n/a

Describe the Bug

When navigating to for example http://localhost:4321/search/?q=hask while running astro preview an error is shown:

image

What's the expected result?

The page should be shown normally

Link to Minimal Reproducible Example

https://stackblitz.com/edit/github-rj7etb?file=src%2Flayouts%2FLayout.astro

Participation

  • I am willing to submit a pull request for this issue.

Metadata

Metadata

Assignees

No one assigned

    Labels

    - P3: minor bugAn edge case that only affects very specific usage (priority)pkg: astroRelated to the core `astro` package (scope)

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions