astro-build-manifest
v1.0.0
Published
Static build manifest of generated pages and assets for Astro sites
Downloads
109
Maintainers
Readme
astro-build-manifest
Static-first build manifest generation for Astro.
astro-build-manifest is a minimal Astro integration that outputs a deterministic
build-manifest.json file at build time, describing exactly what pages and assets
Astro generated.
It is designed for static sites first and never runs at runtime.
Why this plugin exists
After a build, teams often ask:
- What routes were actually generated?
- Did
/about/build correctly? - What files did Astro emit?
- Why is a page missing in production?
Astro already knows this information internally, but does not expose it in a simple, machine-readable way.
astro-build-manifest exposes that data safely and honestly.
What it does (v1)
On astro build, the plugin writes a file to your output directory:
/build-manifest.jsonExample output:
{
"pages": [
"/",
"/about/"
],
"assets": [
"/index.html",
"/about/index.html",
"/_astro/main.abc123.css"
],
"generatedAt": "2026-01-08T19:08:18.024Z"
}What is included
Pages
- All routes Astro generated during the build
- Normalised with leading and trailing slashes
/always represents the homepage
Assets
- Files emitted by Astro’s build pipeline
- HTML entrypoints
- CSS and JavaScript bundles
- Only public, web-facing paths
What is intentionally excluded
- Files in
/public - Environment variables
- Runtime state
- Absolute filesystem paths
- Server or adapter information
This keeps the manifest deterministic, portable, and safe to expose publicly.
Installation
npm install astro-build-manifestUsage
Add the integration to your astro.config.mjs:
import { defineConfig } from "astro/config";
import astroBuildManifest from "astro-build-manifest";
export default defineConfig({
integrations: [
astroBuildManifest()
]
});Then run:
astro buildOutput guarantees
- Static-only
- Deterministic JSON
- Public-safe paths only
- No runtime execution
Versioning
- v1.x — static build manifest only
- v2 (planned) — optional public directory inclusion and diffing
License
MIT
Author
Built and maintained by Velohost
https://velohost.co.uk/
Project homepage:
https://velohost.co.uk/plugins/astro-build-manifest/
