Use relative URLs for Algolia results
What does this MR do and why?
Rewrite Algolia result links so that they point to pages within the site you're on (review apps, localhost, or production) instead of always pointing to docs.gitlab.com.
This uses the transformItems
method in the Algolia API: https://docsearch.algolia.com/docs/api/#transformitems
This should allow for easier testing of Algolia-related changes.
Screenshots, screen recordings, or links to review app
These are strongly recommended to assist reviewers and reduce the time to merge your change.
How to set up and validate locally
Numbered steps to set up and validate the change are strongly suggested.
-
Configure a local GitLab Docs environment: https://gitlab.com/gitlab-org/gitlab-docs/-/blob/main/doc/setup.md. -
Run a search from any of the Algolia search instances (homepage, interior page navbar, /search) -- result links should point within your local site.
Merge request acceptance checklist
This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.
-
I have evaluated the MR acceptance checklist for this merge request.
Edited by Sarah German