Configure your documentation site using runir.config.js — navigation, branding, search, and more.
All site configuration lives in runir.config.js at your project root.
module.exports = {
// Site metadata
name: "My Docs",
description: "Documentation for my project",
// Path to markdown docs (relative to project root)
docsDir: "docs",
// Base URL path — controls where your site is served
// "" → mysite.com/
// "/docs" → mysite.com/docs/
// "/my-repo" → mysite.com/my-repo/ (GitHub Pages)
basePath: "",
// Sidebar navigation
navigation: [
{
title: "Section Name",
links: [
{ title: "Page Title", href: "/page-slug" },
],
},
],
// Top navbar
navbar: {
title: "My Docs",
// logo: "/logo.svg", // custom logo image
// logoWidth: 20,
// logoHeight: 20,
// homeHref: "/", // where logo/title links to
links: [
{ title: "Docs", href: "/" },
{ title: "GitHub", href: "https://github.com", external: true },
],
},
// Theme customization
theme: {
accentColor: "#d97757",
accentColorLight: "#e0896d",
},
// Search settings
search: {
enabled: true,
placeholder: "Search documentation...",
},
// Footer
footer: {
text: "Built with Runir",
links: [],
},
};
basePathControls the URL prefix for your entire docs site. This is the most important setting for deployment.
| Value | Result |
|---|---|
"" |
Site at root: mysite.com/ |
"/docs" |
Site at /docs: mysite.com/docs/ |
"/my-repo" |
For GitHub Pages: username.github.io/my-repo/ |
For GitHub Pages, set basePath to "/your-repo-name". For custom domains or Vercel, you can usually leave it as "".
basePath must match the actual URL root where your site is served — not the URL you want your docs to appear at. For example, if GitHub Pages serves your repo at username.github.io/my-repo/, the correct basePath is "/my-repo".
A common mistake is setting something like basePath: "/my-repo/docs" thinking it will place your docs under a /docs sub-path. This will break all asset loading (CSS, JS, images) because the browser will request files at /my-repo/docs/_next/... while the server only has them at /my-repo/_next/.... If you see 404 errors for _next/static/ files, your basePath is wrong.
docsDirThe directory containing your markdown files. Default is "docs". This is relative to the project root.
docsDir: "content/docs"
You can point this to any directory. If you're migrating from another docs tool, just point docsDir to your existing content folder.
navigationDefines the sidebar structure. Each group has a title and an array of links. The href values are internal paths (the basePath is applied automatically).
navigation: [
{
title: "Getting Started",
links: [
{ title: "Introduction", href: "/" },
{ title: "Quick Start", href: "/quick-start" },
],
},
{
title: "API Reference",
links: [
{ title: "Authentication", href: "/api/auth" },
{ title: "Endpoints", href: "/api/endpoints" },
],
},
],
themeCustomize the accent color used throughout the site.
theme: {
accentColor: "#d97757", // Used for borders, indicators, active states
accentColorLight: "#e0896d", // Used for hover states
}
More theme options (custom fonts, dark/light toggle) are planned for future releases.