A calm web e-reader for public-domain classics and your own DRM-free EPUBs. Real epub.js pagination, fine-press typography, Day/Night themes, synced library.
All project documentation lives in docs/ — see
docs/README.md for the map. Most-used:
DESIGN.md (design language — start there for any visual or
theme work), SPEC.md (scope + architecture),
REVISED_PLAN.md (UI/UX roadmap),
BACKLOG.md (open work),
DEPLOY.md (deploys + migrations).
Build rules for agents are in CLAUDE.md, at the root.
nvm use # Node 22
npm install
npm run dev # http://localhost:3000Working on how Leaf looks? npm run design runs the app on fixtures with no
Supabase, no .env and no login — see docs/DESIGN-LOCAL.md.
| Script | Does |
|---|---|
npm run dev |
dev server |
npm run build |
production build |
npm test |
Vitest |
npm run lint |
ESLint (incl. import-boundary seam rule) |
npm run typecheck |
tsc --noEmit |
npm run format |
Prettier write |
The UI is a swappable layer — a redesign next version should touch only:
src/design/— all design tokens (the only place with literal colors/sizes/fonts); documented inDESIGN.mdsrc/components/— presentational chrome (primitives, reader-ui, library-ui)
Logic (src/reader, src/lib, src/store) is style-agnostic and may not import from
design/ or components/. Enforced by ESLint.
Copy .env.example to .env.local and fill it from your own Supabase project.
No real values are committed — this repo is public.
MIT — see LICENSE.