How itsnavinsingh/img.transform works
Project type and purpose
• This is a full-stack web application called “img.transform” that allows users to upload images and apply affine transformations (rotation, scaling, translation) in real time.
• Frontend: React + TypeScript + TailwindCSS
• Backend: FastAPI + OpenCV + NumPy
• Communication: REST API with multipart/form-data
File structure
Top-level
• main.py – FastAPI entry point
• requirements.txt – Python dependencies
• client/ – React (Vite) application
client/
• package.json, yarn.lock – Node dependencies
• vite.config.ts – build config
• public/ – static assets
• src/
– App.tsx, main.tsx – root React components
– components/ (About.tsx, Home.tsx, imgdrop.tsx, navbar.tsx, footer.tsx)
– constants/routepath.tsx – client routing
– assets/, index.css
• tsconfig*.json – TypeScript configs
No database or external microservices—backend and frontend are packaged together.
README for additional insights
• Confirms layers and tech stack.
• Data flow: image & parameters → POST /transform → FastAPI decodes → OpenCV operations → returns image → UI displays result.
• After building, frontend is served statically from client/dist by FastAPI.