🔥 All-Access Pass — $199 USD (Regular $499) · Unlock all 2,836 Astro themes ➔
komal.nakrani
Get All-Access Pass ($199)
ThemesCategoriesDocsBlogTips & TricksPricingGet All-Access Pass ($199)
Astro Themes••By Komal Nakrani

Aid Astro Theme: Structuring Guides in a Docs Theme

Inside the Aid Astro theme for documentation: getting started, basic, advanced and errors guides, API articles, one-colour branding and docs structure.

#Astro#Astro Themes#Documentation#Docs Theme#Aid

Aid is a minimal Astro documentation theme built around a short, clear guide sequence: Getting Started, Basic Use, Advanced Use and Errors, plus long-form articles such as an introduction to the API. You rebrand it with one main colour swatch and simple classes, and it avoids features a small docs site doesn’t need. It costs $34 one-time, uses Astro 7, Tailwind CSS and TypeScript, and builds to static HTML.

This walkthrough covers what the Aid Astro theme ships, how to structure guides so readers find answers, and how to extend it as your docs grow.

Key Takeaways

  • Aid’s guide set follows the order readers need: start, use, go further, fix problems.
  • Articles hold the explanations and longer walkthroughs that don’t fit a step-by-step guide.
  • Branding is one colour swatch, so a product team can match its palette in minutes.
  • Keep guides in a content collection with an order field to drive the sidebar and next links.
  • For large docs with search, versioning and translations, Starlight may suit you better.

Who the Aid Astro theme is for

Many products need documentation that is short, accurate and easy to scan, not a sprawling portal. A small API, a developer tool, a plugin, an internal platform or a SaaS product’s help centre often fits in a dozen pages. For those, a full documentation framework can be more structure than content.

Aid is built for that size. It’s deliberately minimal: a home page, a sequence of guides and a set of articles, with typography and spacing that keep long pages readable. It sits in our Documentation category, and you can click through every page in the live preview.

The pages it ships

Page Demo path Purpose
Home / What the product is and where to start
Guides: Getting Started /guides_getting-started/ Install, configure, first successful result
Guides: Basic Use /guides_basic-use/ The everyday tasks
Guides: Advanced Use /guides_advanced-use/ Power features and edge cases
Guides: Errors /guides_errors/ Error messages and how to fix them
Article: Familiarizing yourself with our API /articles_familiarizing-yourself-with-our-api/ A guided tour of the API
Article: Using asynchronous programming techniques /articles_using-asynchronous-programming-techniques/ A longer explanation of one topic

The demo uses flat paths such as /guides_getting-started/. If you prefer nested URLs like /guides/getting-started/, move the pages into a guides/ folder under src/pages/ (or generate them from a collection, shown below) before launch. Do it before the site is indexed so you never need redirects.

Why the guide sequence works

Aid’s four guides map to the questions readers bring, in the order they bring them:

  1. Getting Started. “Can I get this working?” Installation and the shortest path to a first result. Measure it in minutes.
  2. Basic Use. “How do I do the normal things?” The tasks most readers repeat every week.
  3. Advanced Use. “How do I do the unusual thing?” Configuration, extension points and performance.
  4. Errors. “Why is it broken?” Every error message, its cause and the fix.

This is close to the split the Diátaxis framework describes (tutorials, how-to guides, reference and explanation), simplified for a small product. The Errors guide is the one teams most often skip, and it’s the page with the highest search value: people paste error messages straight into a search box. Put the exact message text in a heading so it matches.

The articles cover the fourth kind of content, explanation. “Familiarizing yourself with our API” gives context a step-by-step guide can’t, and a piece on asynchronous programming explains the concepts behind the API. Keep them separate from the guides so a reader following steps isn’t pulled into theory.

Guides as a content collection

As docs grow, hand-maintained navigation drifts. Store guides in a collection with an order field, and generate the sidebar and “next guide” links from it.

A generic Astro 7 sketch of the pattern (not the theme’s exact files):

// src/content.config.ts
import { defineCollection } from 'astro:content';
import { glob } from 'astro/loaders';
import { z } from 'astro/zod';

const guides = defineCollection({
  loader: glob({ pattern: '**/*.mdx', base: './src/content/guides' }),
  schema: z.object({
    title: z.string(),
    description: z.string().max(160),
    section: z.enum(['start', 'use', 'advanced', 'errors']),
    order: z.number(),
    updated: z.coerce.date(),
  }),
});

const articles = defineCollection({
  loader: glob({ pattern: '**/*.mdx', base: './src/content/articles' }),
  schema: z.object({ title: z.string(), description: z.string(), pubDate: z.coerce.date() }),
});

export const collections = { guides, articles };

Then one dynamic route renders every guide with nested URLs:

---
// src/pages/guides/[...slug].astro
import { getCollection, render } from 'astro:content';
import DocsLayout from '../../layouts/DocsLayout.astro';

export async function getStaticPaths() {
  const guides = (await getCollection('guides')).sort((a, b) => a.data.order - b.data.order);
  return guides.map((guide, i) => ({
    params: { slug: guide.id },
    props: { guide, next: guides[i + 1], prev: guides[i - 1] },
  }));
}

const { guide, next, prev } = Astro.props;
const { Content } = await render(guide);
---
<DocsLayout title={guide.data.title} description={guide.data.description}>
  <Content />
  <nav class="pager" aria-label="Guide navigation">
    {prev && <a href={`/guides/${prev.id}/`} rel="prev">Previous: {prev.data.title}</a>}
    {next && <a href={`/guides/${next.id}/`} rel="next">Next: {next.data.title}</a>}
  </nav>
</DocsLayout>

Adding a guide is now one file. The order, the sidebar and the previous and next links update on the next build. Our tip on previous and next links in Astro covers the pager in more detail.

One colour swatch for branding

Aid is themed with one main colour. That’s a sensible constraint for documentation: the brand colour marks links, active sidebar items and callouts, and everything else stays neutral so code and text are easy to read.

If you want the swatch in one place you can change, expose it as a CSS custom property and point Tailwind at it:

/* src/styles/brand.css */
:root {
  --brand: 37 99 235; /* RGB channels, so Tailwind can apply opacity */
}
// tailwind.config.mjs (excerpt)
export default {
  theme: {
    extend: {
      colors: { brand: 'rgb(var(--brand) / <alpha-value>)' },
    },
  },
};

Classes like text-brand and bg-brand/10 then follow the variable. Check contrast for link text against the background; a mid-blue that works on a button can fail as body-size link text. The styling docs explain how Komal themes organise design tokens.

Writing the Errors guide

The Errors guide deserves its own process:

  1. Collect every message your product can show, from the code, not from memory.
  2. Use the exact text as the heading, in a code span, so a search for the message lands on it.
  3. Explain the cause in one sentence, then give the fix with a code sample.
  4. Link related errors where one often follows another.

Give each error a heading id so support can send a direct link, such as /guides/errors/#invalid-api-key.

Adding search as the docs grow

Under twenty pages, a clear sidebar is enough. Past that, readers want search. Pagefind indexes the built HTML and runs entirely in the browser, so it fits a static theme like Aid with no server or third-party account. Our guide to Pagefind search in Astro walks through the setup.

Customising Aid

  1. Clone and run. Purchase sends an invitation to the theme’s private GitHub repository. Clone it, run npm install and npm run dev.
  2. Set the brand colour and logo.
  3. Decide your URL structure (flat or nested) before writing content.
  4. Write Getting Started first, and test it on someone who has never used the product.
  5. Fill the Errors guide from the code’s real messages.
  6. Move API tours and concepts into articles.
  7. Build and deploy dist/ to any static host.

The commercial licence covers your own docs and docs you build for paying clients, and updates are free for life.

Aid compared with Starlight and other routes

Starlight, Astro’s official documentation framework, is free and excellent. It ships search, a generated sidebar, internationalisation, dark mode, accessible navigation and a plugin ecosystem. If your docs will run to hundreds of pages, need translations or versioning, or you want the conventions Astro’s own docs use, start there. Our comparison of plain Astro or Starlight for docs helps you decide, and the Starlight docs cover setup.

Choose Starlight if you need its built-in features and are happy with its layout conventions. Choose Aid if your docs are small to medium, you want a distinctive, minimal design you control completely, and a clear four-part guide structure is enough. Our roundup of the best Astro documentation templates compares more options, and the Aid theme page has the full listing.

FAQ

What is the Aid Astro theme?

Aid is a $34 minimal documentation theme built with Astro 7, Tailwind CSS and TypeScript. It ships a home page, four guides (Getting Started, Basic Use, Advanced Use and Errors) and long-form articles, and you rebrand it with one main colour.

How should documentation guides be structured?

Start with a getting-started guide that reaches a first result quickly, then everyday tasks, then advanced topics, then an errors reference. Keep explanations and concepts in separate articles so step-by-step guides stay focused.

Is Aid a Starlight theme?

No. Aid is a standalone Astro project, not a Starlight theme or plugin. That gives you full control of the layout, but you add features like search yourself.

Can I add search to the Aid documentation theme?

Yes. Pagefind works well with a static Astro docs site. It indexes the built HTML after astro build and runs in the browser, so there’s no server to host.

Does Aid support versioned documentation?

Not out of the box. For a small number of versions, you can add a version folder per release. If versioning is central to your docs, a framework with built-in support is a better fit.