How praduman1916/insyd-poc-frontend works
Project type and purpose
• This is a frontend‐only Proof of Concept (POC) built with Next.js (App Router), Tailwind CSS, and Axios.
• Its sole purpose is to let users submit and view notifications in real time, leveraging a separate backend (hosted on Railway) via REST endpoints.
File structure
• Top level: project configuration files (next.config.mjs, jsconfig.json, Tailwind and PostCSS configs), package.json, README.
• public/: static assets.
• src/app/: Next.js App Router layer containing global styles (globals.css), layout (layout.js), page entrypoint (page.js), and a client‐side service module (api/notificationService.js) that wraps calls to the external API.
• src/components/: React UI building blocks—NotificationForm.jsx and NotificationList.jsx.
• src/utils/: reusable utilities, specifically axiosInstance.js (preconfigured Axios client).
README for additional insights
• Core features: adding notifications, infinite scroll, real‐time updates.
• API endpoints: POST and GET on /api/v1/notifications served by the backend.
• Deployment: Frontend auto‐deployed on Vercel; backend on Railway.
• Next.js App Router (layout.js, page.js)
• NotificationForm.jsx (POST → /notifications)
• NotificationList.jsx (GET → /notifications, infinite scroll)
• axiosInstance.js (base URL, interceptors)
• notificationService.js (wrapper methods: createNotification(), fetchNotifications())
• External Backend API endpoints /api/v1/notifications
• Database persistence layer