-
Notifications
You must be signed in to change notification settings - Fork 3.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add breadcrumbs to search results #2772
base: main
Are you sure you want to change the base?
Conversation
🦋 Changeset detectedLatest commit: 3eff78d The changes in this PR will be included in the next version bump. This PR includes changesets to release 1 package
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
@@ -317,12 +320,15 @@ async function transformSectionsAndPage(args: { | |||
})) ?? [], | |||
); | |||
|
|||
const pageData = await fetchPageData({ pathname: [item.path] }); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This function correctly gets the page data when the page is in the same space as we're currently searching in, but doesn't work when we need to search across sections/variants. Any suggestions to make it work are welcome.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We should not use this function as it's tied to the current context, and generally, it'll make things slower by fetching a lot of data to render search results.
We need to think about a different approach, potentially by changing our API, because otherwise, this PR could badly impact performances.
GitBook Preview |
The latest updates on your projects. Learn more about Argos notifications ↗︎
|
Summary of the deployments: Version 1 (production)
Version 2 (experimental)
Test content |
When the search displays many similarly named pages, the user has no idea which search result leads where on the site or which result they actually need.
By adding breadcrumbs, we make it easier to understand what content we're matching.