Centralized VitePress documentation site for all Unopim extensions, deployed at docs-extensions.unopim.com.
This repo holds only the VitePress shell, theme, and nav config. Each extension's content lives in its own repo and is pulled into docs/{slug}/ at build time by the GitHub Action.
npm install
npm run docs:dev # starts at http://localhost:5173
npm run docs:build # outputs to docs/.vitepress/dist
npm run docs:preview # preview the production build locallydocs/
.vitepress/
config.ts # nav, sidebar, base URL
public/
CNAME # custom domain for GitHub Pages
{slug}/
index.md # placeholder only — real content pulled at build time
- Extension content — edit docs in the extension's own repo (
docs/folder there), not here. - Site shell — branch from
main, changedocs/.vitepress/, verify withdocs:dev+docs:build, open a PR.
Follow these steps when a new Unopim extension needs a documentation section.
Create a docs/ folder in the extension repo with your markdown files and a sidebar.json:
[
{
"text": "My Module",
"items": [
{ "text": "Overview", "link": "/my-module/" },
{ "text": "Installation", "link": "/my-module/installation" },
{ "text": "Configuration", "link": "/my-module/configuration" }
]
}
]Use relative links in markdown (./installation, not /installation).
Create docs/{slug}/index.md:
# My Module
Placeholder — real docs are pulled from `unopim/unopim-my-module` at build time.Add one line to the projects array in docs/.vitepress/config.ts:
{ slug: 'my-module', label: 'My Module' },This wires up the nav dropdown, sidebar, and edit links automatically.
In .github/workflows/deploy.yml, add a step to checkout the module repo and copy its docs/ into docs/{slug}/ before the build. Follow the pattern of existing modules.
Run npm run docs:dev (confirm the route loads) and npm run docs:build (no errors), then submit a PR with the placeholder, config.ts change, and workflow change.