How arthurhoang15/learnflow-front-end-webapp works
Project type and purpose
• This is a single-page application (SPA) front-end built with ReactJS and Vite in TypeScript. It powers the UI of LearnFlow, an interactive, gamified English-learning platform.
• It provides routing between “pages” (Home, Login, Stories, Smart Learning, Admin panels, etc.), reusable UI components, an API-calling layer, and mock data for local development.
File structure
• Top-level:
• public/index.html → HTML entry point
• src/main.tsx → React entry point, mounts <App/>
• src/App.tsx → Defines top-level router and layout
• vite.config.ts / tsconfig*.json → Build and tooling config
• vercel.json → Deployment config
• Under src:
• src/pages/… → Route-level components (one per URL)
• src/components/… → Reusable UI widgets (cards, navbars, modals)
• src/api/… → Service modules to call backend REST endpoints (dictionary, faq)
• src/mocks/data/… → JSON fixtures for offline/dev mode
• src/assets/images → Static assets imported by components
• src/routes/index.tsx → Route definitions for React Router
README for additional insights
• Confirms ReactJS, responsive UI, user authentication (incl. Google OAuth2), gamified lessons, community features, progress tracking.
• Mentions “services” for API logic (in this codebase under src/api).
• Describes typical dev workflow and branch/commit conventions.
Thoroughness
• Every folder’s responsibility: pages vs. components vs. api vs. mocks vs. assets
• SPA pattern and its data-flow (user action → component → service → backend → state → render)
• Don’t omit any key path (e.g., OAuth, mock bypass, static asset loading)