Starlight
The @lunariajs/starlight
package integrates Lunaria into the Starlight documentation theme for Astro, adding the Lunaria dashboard as part of your Astro site with Starlight.
Set up
-
If you haven’t already, follow the steps to add Lunaria to your project in the Getting Started guide.
-
Add the
@lunariajs/starlight
to your project with your preferred package manager: -
Add the
@lunariajs/starlight
plugin to Starlight’splugins
array field:
Usage
By default, a new /lunaria
route will be added to your Astro site and will be built alongside your site’s production build. This route can be changed using the integration’s route
option.
Your dashboard will also be available during development, although the first access might be slow thanks to Lunaria generating its status on the spot. The status will be cached for subsequent navigations and will be invalidated when a new commit is added.
Options
sync
Type: boolean
Default: false
Specifies if your Lunaria configuration’s defaultLocale
, locales
, and files
fields should be synced with your Starlight i18n configuration when you use the astro build
command:
route
Type: string
Default: "/lunaria"
The route where the Lunaria dashboard will be injected on. The value must be a valid Astro route pattern string:
configPath
Type: string
Default: "./lunaria.config.json"
The relative path to your Lunaria configuration file: