Skip to content

Technology Stack ​

Complete Technology Inventory ​

This document provides a comprehensive listing of all technologies, frameworks, libraries, and services used in the PeopleHub platform.

Backend Stack ​

Runtime & Core Framework ​

TechnologyVersionPurpose
Node.js22.x LTSJavaScript runtime (latest LTS in 2025)
TypeScript5.9.2Type-safe JavaScript
Fastify5.5.0High-performance web framework
ES ModulesNativeModern JavaScript module system

Why Fastify over Express?

  • 2-3x faster request handling
  • Built-in schema validation with Ajv
  • Native TypeScript support
  • Plugin architecture for extensibility
  • Better error handling out-of-the-box

Database & ORM ​

TechnologyVersionPurpose
PostgreSQL17.5Primary relational database
Drizzle ORM0.44.4Type-safe SQL query builder
pg8.16.3PostgreSQL client for Node.js
Drizzle Kit0.31.4Database migrations and introspection

Drizzle ORM Benefits:

typescript
// Type-safe queries with autocomplete
const employees = await db
  .select()
  .from(employeeTable)
  .where(eq(employeeTable.status, 'active'))
  .orderBy(employeeTable.joiningDate);
// TypeScript knows exact return type!
  • SQL-like syntax (not ORM magic)
  • Zero runtime overhead
  • Perfect TypeScript inference
  • Lightweight (<10KB)
  • Generate types from database schema

​

Authentication & Security

TechnologyVersionPurpose
@fastify/jwt10.0.0JWT token generation and validation
@fastify/cookie11.0.2Cookie parsing and serialization
bcryptjs3.0.2Password hashing
Zod4.1.3Runtime schema validation
Ajv8.17.1JSON schema validation

JWT Authentication Flow:

  • Access token: 4 hours (short-lived)
  • Refresh token: 7 days (HTTP-only cookie)
  • Bcrypt rounds: 10 (secure password hashing)

AWS SDK & Services ​

TechnologyVersionPurpose
@aws-sdk/client-s33.894.0S3 file storage operations
@aws-sdk/s3-request-presigner3.891.0Generate presigned S3 URLs
@aws-sdk/client-ses3.901.0Email sending (notifications service)
@fastify/aws-lambda6.1.1Fastify Lambda adapter

Build & Deployment (Backend) ​

TechnologyVersionPurpose
Serverless Framework4.21.0Infrastructure as code, deployment
serverless-offline14.4.0Local Lambda development
esbuild0.25.11Fast JavaScript bundler
tsx4.20.4TypeScript execution and watch mode

Deployment Configuration:

yaml
provider:
  runtime: nodejs22.x
  region: ap-south-1
  memorySize: 1024
  timeout: 10

build:
  esbuild:
    bundle: true
    minify: true
    sourcemap: true
    target: node22

Development Tools (Backend) ​

TechnologyVersionPurpose
ESLint9.33.0Code linting
Prettier3.6.2Code formatting
TypeScript ESLint8.40.0TypeScript-specific linting
simple-git-hooks2.13.1Git pre-commit hooks
Jest29.7.0Testing framework

Frontend Stack ​

Core Framework & Build Tools ​

TechnologyVersionPurpose
React19.1.0UI framework (latest)
TypeScript5.8.3Type-safe JavaScript
Vite7.0.4Build tool and dev server
@vitejs/plugin-react-swcLatestFast refresh with SWC

Why Vite over Create React App?

  • 10-100x faster hot module replacement (HMR)
  • Native ES modules (no bundling in dev)
  • Optimized production builds with Rollup
  • < 1 second cold start
  • Built-in TypeScript support

Routing & Navigation ​

TechnologyVersionPurpose
@tanstack/react-router1.130.12Type-safe, file-based routing

TanStack Router Benefits:

typescript
// Type-safe route navigation
navigate({
  to: '/employees/$employeeId',
  params: { employeeId: '123' }, // TypeScript validates this!
  search: { tab: 'documents' }
});
  • File-based routing (Next.js-like)
  • Full TypeScript support
  • Built-in route guards and loaders
  • Search params validation with Zod
  • 100+ routes in PeopleHub

State Management ​

TechnologyVersionPurpose
Zustand5.0.8Client-side state management
@tanstack/react-query5.85.5Server state management

Why This Combination?

Zustand (Local State):

  • Auth state (user, tokens, permissions)
  • UI state (sidebar open/closed, modals)
  • Lightweight (<1KB)
  • No boilerplate (unlike Redux)

TanStack Query (Server State):

  • API data fetching and caching
  • Automatic background refetching
  • Optimistic updates
  • Request deduplication
  • 5-minute stale time

Forms & Validation ​

TechnologyVersionPurpose
react-hook-form7.62.0Form state management
@hookform/resolvers5.2.1Form validation resolvers
Zod4.0.14Schema validation

Form Handling Pattern:

typescript
const schema = z.object({
  email: z.string().email(),
  password: z.string().min(8)
});

const { register, handleSubmit } = useForm({
  resolver: zodResolver(schema)
});

Benefits:

  • Type-safe form values
  • Runtime validation
  • Client-side + server-side validation reuse
  • Excellent performance (fewer re-renders)

UI Components & Styling ​

TechnologyVersionPurpose
Radix UIVariousHeadless accessible components (40+)
Tailwind CSS4.1.11Utility-first CSS framework
@tailwindcss/viteLatestVite integration for Tailwind
Lucide React0.536.0Icon library (2000+ icons)
Framer Motion12.23.12Animation library

Radix UI Components Used:

  • Dialog, Popover, Dropdown Menu, Tooltip
  • Checkbox, Radio Group, Switch, Select
  • Tabs, Accordion, Collapsible
  • Alert Dialog, Context Menu, Hover Card
  • Form primitives, Label, Separator
  • Scroll Area, Slider, Toggle

Why Radix UI?

  • Unstyled (full design control with Tailwind)
  • Accessibility built-in (ARIA attributes, keyboard navigation)
  • No CSS conflicts
  • Tree-shakeable (only import what you use)

Data Visualization & UI Enhancements ​

TechnologyVersionPurpose
Recharts2.15.4Charts and graphs
date-fns4.1.0Date manipulation
react-day-picker9.8.1Date picker component
Sonner2.0.7Toast notifications

HTTP Client ​

TechnologyVersionPurpose
Axios1.12.2HTTP client with interceptors

API Client Features:

  • Automatic JWT token attachment
  • 401 handling with token refresh
  • Request/response interceptors
  • Error normalization
  • Base URL configuration per environment

AWS Integration (Frontend) ​

TechnologyVersionPurpose
@aws-sdk/client-s33.894.0S3 file uploads
@aws-sdk/s3-request-presignerLatestGenerate presigned upload URLs

File Upload Pattern:

  1. Request presigned URL from backend
  2. Upload directly to S3 from browser
  3. No file data through Lambda (cost efficient)

Development Tools (Frontend) ​

TechnologyVersionPurpose
ESLint9.33.0Code linting
Prettier3.6.2Code formatting
TypeScript ESLint8.40.0TypeScript linting

Infrastructure & DevOps ​

AWS Services ​

ServicePurposeConfiguration
AWS LambdaServerless computeNode.js 22.x, 1024MB RAM, 10s timeout
API GatewayHTTP API routingHTTP API (not REST API)
RDS PostgreSQLDatabaseMulti-AZ, PostgreSQL 17.5
S3Object storageDocuments, images, frontend hosting
CloudFrontCDNGlobal edge locations, HTTPS only
AWS Secrets ManagerSecrets storageAuto-rotation enabled (30 days)
AWS SESEmail sendingTransactional emails
CloudWatchLogging & monitoringLambda logs, RDS metrics
IAMAccess controlLeast-privilege policies

CI/CD ​

TechnologyPurpose
GitHub ActionsCI/CD pipelines
Node.js 18CI runner environment
npmPackage management
Serverless CLIBackend deployment
AWS CLIS3 sync, CloudFront invalidation

Deployment Workflows:

Frontend (deploy-dev.yml):

  1. Checkout code
  2. Install dependencies (npm ci)
  3. Build with Vite (vite build --mode production)
  4. Sync to S3 bucket
  5. Invalidate CloudFront cache

Backend (deploy-backend.yml):

  1. Checkout code
  2. Install dependencies
  3. Run TypeScript compilation
  4. Deploy with Serverless Framework
  5. Test health endpoint

Deployment Times:

  • Frontend: <2 minutes
  • Backend: ❤️ minutes

Python Service (PDF Generation) ​

Runtime & Framework ​

TechnologyVersionPurpose
Python3.11+Runtime for PDF generation
Weazy PrintLatestHTML to PDF conversion
Fastify(Via Lambda)HTTP endpoint wrapper

Why Python for PDF?

  • Weazy Print: Best HTML-to-PDF library
  • Complex CSS support
  • Mature ecosystem for document generation

Database Schema ​

PostgreSQL Features Used ​

FeatureUse Case
JSONBFlexible metadata storage
Foreign KeysData integrity enforcement
IndexesQuery performance optimization
TriggersAudit trail automation
ViewsComplex query simplification
CTEsRecursive org chart queries

Schema Statistics:

  • Tables: 140+ tables
  • Relationships: Complex foreign key relationships
  • Indexes: Optimized for common query patterns
  • Data Volume: Designed for millions of records

Development Environment ​

Required Tools ​

ToolVersionPurpose
Node.js22.x+Backend runtime
npm10.x+Package manager
Python3.11+PDF service
PostgreSQL17.xLocal database (optional)
Git2.x+Version control
AWS CLI2.x+AWS deployments
Serverless CLI4.x+Lambda deployments

IDE Recommendations ​

VS Code Extensions:

  • ESLint
  • Prettier
  • TypeScript and JavaScript Language Features
  • Tailwind CSS IntelliSense
  • PostgreSQL (for database queries)
  • Thunder Client (API testing)

Version Management Strategy ​

Semantic Versioning ​

All packages use semantic versioning (semver):

  • Major: Breaking changes
  • Minor: New features (backward compatible)
  • Patch: Bug fixes

Update Strategy ​

Dependencies:

  • Monthly security updates
  • Quarterly feature updates
  • Annual major version upgrades (with testing)

Lock Files:

  • package-lock.json committed to git
  • Ensures reproducible builds across environments

Performance Optimization ​

Bundle Size Optimization ​

Frontend:

  • Code splitting: Separate chunks per route
  • Tree shaking: Remove unused code
  • Dynamic imports: Load components on demand
  • Total bundle: ~3.1MB (optimized)

Backend:

  • esbuild minification
  • Lambda package: ~1.5MB per service
  • Excludes dev dependencies
  • Cold start: <500ms

Runtime Optimization ​

Database:

  • Connection pooling (10 connections per Lambda)
  • Query optimization with indexes
  • Pagination for large result sets

API:

  • Response caching (where applicable)
  • Compression (gzip/brotli)
  • Efficient JSON serialization

Security Tools & Practices ​

Code Security ​

ToolPurpose
ESLint security rulesDetect security issues in code
Zod validationRuntime input validation
Pre-commit hooksPrevent bad commits
Secrets scanningDetect committed secrets

Infrastructure Security ​

ServicePurpose
AWS Secrets ManagerStore credentials securely
IAM rolesLeast-privilege access
VPCNetwork isolation (production plan)
WAFWeb application firewall (planned)
GuardDutyThreat detection (planned)

Monitoring & Observability ​

Current Tools ​

ToolPurpose
CloudWatch LogsLambda and application logs
CloudWatch MetricsLambda performance metrics
RDS Performance InsightsDatabase query analysis

Planned Tools ​

ToolPurpose
X-RayDistributed tracing
CloudWatch AlarmsProactive alerting
Custom DashboardsReal-time monitoring

Technology Selection Criteria ​

Every technology in PeopleHub was chosen based on:

  1. Performance: Must deliver sub-second response times
  2. Type Safety: TypeScript support required
  3. Maturity: Production-ready, stable releases
  4. Community: Active maintenance and ecosystem
  5. Cost: Open-source preferred, no vendor lock-in
  6. Learning Curve: Team familiarity or easy to learn
  7. Future-Proof: Modern, growing adoption

Technology Upgrade Path ​

Short-Term (Next 6 Months) ​

  • All technologies up-to-date as of November 2025
  • Quarterly dependency updates
  • Security patches as released

Medium-Term (6-12 Months) ​

  • Add X-Ray tracing for observability
  • Implement WAF rules for API protection
  • Setup GuardDuty for threat detection
  • Add CloudWatch custom dashboards

Long-Term (12+ Months) ​

  • Evaluate React 20+ features when released
  • Consider Aurora Serverless v3 (if better than RDS)
  • Multi-region deployment for global offices
  • Advanced caching strategies (Redis/ElastiCache)

Technology Stack Last Reviewed: January 2025