Skip to content

Configuration

The nebari() plugin is deliberately small — most of what you’ll configure lives in Starlight’s own options. This page covers both: the theme’s options, and the Starlight settings that matter most for a pack.

Pass options as an object to the plugin:

astro.config.mjs
starlight({
title: 'My Pack',
plugins: [
nebari({ logoHref: 'https://packs.nebari.dev/' }),
],
});

Where the header logo links to. Defaults to the site’s own base (import.meta.env.BASE_URL), so clicking the logo returns to your pack’s home. Set it to the portal root when your pack is one of many served under a shared domain:

nebari({ logoHref: 'https://packs.nebari.dev/' });

See the Configuration Options reference for the full option table and defaults.

The theme leaves these to you — they’re per-pack decisions.

astro.config.mjs
starlight({
title: 'My Pack',
description: 'Documentation for the My Pack Nebari extension.',
plugins: [nebari()],
});

Define your information architecture explicitly, or let Starlight autogenerate it from the file tree. This site uses explicit groups so it can nest and collapse:

astro.config.mjs
sidebar: [
{
label: 'Getting Started',
items: [
{ label: 'Installation', link: '/getting-started/installation/' },
{ label: 'Quickstart', link: '/getting-started/quickstart/' },
],
},
{
label: 'Reference',
collapsed: true, // starts collapsed
autogenerate: { directory: 'reference' },
},
],

If your pack is served from a subpath (for example packs.nebari.dev/my-pack), set base so every asset and link is prefixed correctly:

export default defineConfig({
base: '/my-pack',
integrations: [starlight({ title: 'My Pack', plugins: [nebari()] })],
});

The theme’s CSS loads before any customCss you provide, so you can override individual design tokens without forking:

src/styles/overrides.css
:root {
/* Nudge the accent for a sub-brand */
--sl-color-accent: oklch(0.6 0.2 320);
}
astro.config.mjs
starlight({
plugins: [nebari()],
customCss: ['./src/styles/overrides.css'],
});