Star Warp
This integration adds a quick “jump to first search result” URL to any Astro site using Pagefind. With that, your users can search within your website from their browsers search bar directly.
Installing the integration
How to use
With the integration installed, navigating to <your site>/warp?q=your search term
will navigate to the first result of that search.
For example, go to https://inox-tools.fryuni.dev/warp?q=logger and see where you land :)
This works completely statically, you don’t need SSR to use this integration.
Using with Starlight
This integration is also a Starlight plugin to get better defaults from your Starlight site!
Just move it from the integrations
property on your astro.config.mjs
to the plugins
property in side the Starlight integration:
Configuration
path
Type: string
Default: /warp
The path of the warp route.
openSearch.enabled
Type: boolean
Whether an OpenSearch Description should be generated on the configured path
followed by .xml
.
Defaults to false
when used as an Astro Integration and true
when used as a Starlight plugin.
openSearch.title
Type: string
The OpenSearch Description’s site search title.
Defaults to the Starlight title when used as a Starlight plugin and the string “Astro Site” when used as an Astro Integration.
openSearch.description
Type: string
Default: Search <title>
where <title>
is the OpenSearch Description’s site search title.
The OpenSearch Description’s site search description.
License
Star Warp is available under the MIT license.