Bilingual WorkspaceBilingual Workspace

ภาพรวมระบบWorkspace Overview

ระบบจะเปลี่ยนหัวข้อด้านบนตามหน้าปัจจุบันและหัวข้อเมนูที่กำลังใช้งานThe top bar updates itself from the current route and active navigation topic.

Architecture

โครงสร้างที่ใช้บน CloudflareCloudflare Delivery Architecture

rinbooks แยก frontend กับ backend ชัดเจน แต่ยังอยู่ใน repo เดียวเพื่อให้ deploy และส่งงานต่อทีมได้ง่ายrinbooks keeps frontend and backend separate while staying in one repo, which makes deployment and handoff simpler.

  • web/ build เป็น static files แล้วเสิร์ฟผ่าน Cloudflare Pages บน rinbooks.comweb/ builds to static files and is served by Cloudflare Pages on rinbooks.com.
  • worker/ เป็น API สำหรับหนังสือ การยืมคืน และอัปโหลดปกผ่าน route /api/*worker/ handles books, loans, and cover uploads through the /api/* routes.
  • Postgres เช่น Neon หรือ Supabase เก็บแคตตาล็อกและรายการยืมPostgres, such as Neon or Supabase, stores catalog and loan records.
  • R2 เก็บรูปปกและเสิร์ฟกลับผ่าน Worker route เดียวกันR2 stores cover images and serves them back through the same Worker.
  • Push เข้า GitHub แล้ว Pages กับ Worker deploy ต่อให้อัตโนมัติPush to GitHub and let Pages plus Worker deployments continue automatically.