How rahulkamilya/no-pass works
Project type and purpose
• This is a client-heavy, single-page full-stack web application (a password manager) built with React/TypeScript, Vite, Tailwind CSS, and shadcn-ui.
• It delegates all server-side concerns (authentication, data storage) to Firebase (Auth & Firestore).
File structure
• Top-level files: Vite configs (vite.config.ts), Tailwind config (tailwind.config.ts), tsconfig files, package managers’ lockfiles.
• public/: static assets (manifest.json, robots.txt).
• src/: core source tree
· pages/: Next-style route components (Dashboard, Home, NotFound).
· components/: UI building blocks and feature widgets (AddPasswordForm, PasswordList, SearchBar).
· components/ui/: shadcn-ui primitives.
· contexts/AuthContext.tsx: global auth state provider.
· hooks/: custom React hooks (useFirestore, useToast, useMobile).
· lib/firebase.ts: Firebase initialization.
· services/dataService.ts: wrapper over Firestore CRUD.
• No server code: all “backend” calls go to Firebase.
README for additional insights
• Confirms tech stack (Vite, React, TypeScript, Tailwind, shadcn-ui).
• Deployment is a static site (hosted via Lovable), with optional custom domains.
Main components
a. Frontend SPA (React app)
• UI layer: shadcn-ui + Tailwind CSS
• Routing layer: src/pages + React Router (or similar)
• State & Context: AuthContext, React state/hooks
• Feature modules: PasswordList, AddPasswordForm, SearchBar, UserProfileForm
b. Backend-as-a-Service (Firebase)
• Firebase Authentication
• Firestore database
c. Development & Build toolchain
• Node.js environment + Vite (dev server, HMR, build)
d. Hosting / CDN
• Static file host (Lovable CDN or any static-site host)
e. External integrations
• Browser local storage or Cookies (for storing auth tokens)
• Optional external domain via DNS
Relationships & interactions
• Client ↔ Firebase Auth: signup, login, token lifecycle
• Client ↔ Firestore: CRUD operations on password records via dataService & useFirestore hook
• Client UI ↔ Contexts/Hooks: share auth state, show toast notifications, responsive behavior
• Developer’s machine ↔ Vite Dev Server: code edit → hot reload
• CI/CD/Hosting: build artifacts pushed to CDN
Architectural patterns & design principles
• Component-based architecture (atomic UI + feature components)
• Unidirectional data flow (React state → props → events → service calls → state updates)
• Context API for cross-cutting concerns (authentication, theming, toasts)
• Service layer for remote data (dataService abstraction over Firestore)
• Separation of concerns: UI, hooks, contexts, services, lib