tabula-docs
v0.1.4
Published
Static, dependency-free API documentation driven by a single JSON file.
Maintainers
Readme
Tabula
Static, dependency-free API documentation driven by a single JSON file.
[!NOTE] Most of the non-source files in this repository — documentation, CI workflows, CLI scripts, and configuration — were largely generated with the help of Claude. The source files (
src/) were written by hand and reviewed carefully. That said, if you spot anything insecure or incorrect anywhere in the repo, please don't hesitate to open an issue or submit a PR — all reports are welcome and appreciated.
Why Tabula?
- Zero runtime dependencies. Pure HTML + CSS + vanilla JavaScript. No React, no build step, no
node_modulesto serve. - One source of truth. Edit
api.json, reload — your docs are up to date. - Framework agnostic. PHP, Go, Python, Rust, Node — Tabula doesn't care what's behind your API.
- Machine-validated. A built-in linter catches schema errors before they reach the browser.
- Themeable. Colors, fonts, logo, dark mode — all from the
settingsblock, no CSS editing needed.
Quickstart
# 1. Scaffold a new docs folder
npx tabula-docs init my-docs
# 2. Edit your API schema
cd my-docs && $EDITOR api.json
# 3. Preview locally
npx tabula-docs serve .Open http://localhost:3000. Done.
Manual setup
No CLI needed. Copy src/ into your project, drop your api.json next to index.html, and serve with any static server.
my-docs/
├── index.html
├── assets/
│ ├── images/
│ ├── scripts/
│ │ ├── pretty-json.js
│ │ ├── constants.js
│ │ ├── endpoints.js
│ │ ├── inputs.js
│ │ └── script.js
│ └── styles/
│ └── styles.css
└── api.json ← your fileValidate your schema
npx tabula-docs validate path/to/api.jsonExit 0 = all clear. Exit 1 = errors to fix before deploying.
See docs/validator.md for the full list of checks.
Examples
| Example | Description |
| ---------------------------------------------------- | ------------------------------------------------------------ |
| examples/minimal/ | Two tables, ready in 30 seconds |
| examples/blog/ | Realistic CRUD — posts, users, tags, pagination |
| examples/ecommerce/ | Advanced — multipart uploads, order state machine, full auth |
Documentation
| Doc | Content |
| ------------------------------------------------------ | ----------------------------------------------- |
| docs/getting-started.md | CLI and manual setup walkthrough |
| docs/schema-reference.md | Complete api.json field reference |
| docs/theming.md | Colors, fonts, logo, dark mode |
| docs/custom-endpoints.md | Non-CRUD endpoints, file uploads |
| docs/validator.md | Linter usage and GitHub Actions integration |
| docs/deployment.md | GitHub Pages, Vercel, Netlify, Cloudflare Pages |
Contributing
Contributions are welcome. See CONTRIBUTING.md for setup instructions, commit conventions, and the PR process.
License
MIT © Lauwed
