How alexanderthebored/book-animation-test works
Project type and purpose
• This is a static, full-stack-lite web application for browsing and reading manga.
• It provides a library view (index.html) and a reader view (mangareader.html), uses a local JSON data file and image assets, and includes CLI tools for asset management.
File structure
• Top level:
• index.html (Library page)
• mangareader.html (Reader page)
• data/manga.json (Metadata store)
• assets/ (covers + per-manga chapter images)
• components/ (reusable UI modules: book-card, header, logo)
• styles/main.css (global styling)
• tools/ (Node scripts for downloading manga and generating JSON)
• dev-tools/admin.html (CLI command UI)
• No server-side code: static files are served by any HTTP server.
Key README insights
• The app loads manga.json, renders animated book cards, and on click navigates to the reader which fetches images by path.
• CLI tools automate downloading and organizing images and JSON metadata.
Main components & relationships
a. Frontend Pages
• Library Page (index.html)
• Reader Page (mangareader.html)
b. Data Layer
• manga.json (fetched via HTTP)
• assets/covers/*.jpg|png (cover images)
• assets/manga/[folder]/ch-X/page-NNN.jpg (chapter pages)
c. UI Components
• book-card (handles animation, click → openReader)
• header & logo (static branding)
d. Tooling
• Node scripts under tools/ (batch-download, generate JSON, etc.)
• dev-tools/admin.html (converts MangaDex links → CLI commands)
Interactions & Data Flow
• Browser requests index.html → loads CSS, book-card.js, fetches manga.json → renders book cards with cover images.
• On “Open Reader”: browser navigates to mangareader.html?slug=[manga] → fetches corresponding folder and chapter image assets.
Architectural patterns & principles
• Component-based UI (simple “vanilla” Web Components / JS modules).
• Clear separation: data (JSON & images) vs. presentation (HTML/CSS/JS).
• Static-only architecture: no backend; everything fetched over HTTP.