A full-stack TypeScript application for managing household expenses. Built with a monorepo structure using Turborepo.
- User Authentication: Secure JWT-based authentication system
- Expense Management: Create, update, delete, and categorize expenses
- Categories: Organize expenses by customizable categories
- Dashboard: Visualize spending patterns
- Responsive UI: Works on mobile and desktop
- React (with Vite)
- TypeScript
- Material-UI
- React Router
- Formik & Yup (form handling)
- Nivo (data visualization)
- Axios (API client)
- Node.js
- Express.js
- TypeScript
- PostgreSQL (with node-postgres)
- JWT Authentication
- Turborepo (monorepo management)
- ESLint
- TypeScript
- PM2 (production process management)
expenses-fullstack-js/
├── apps/
│ ├── api/ # Express.js backend
│ └── web/ # React frontend
├── packages/
│ └── shared/ # Shared types and utilities
└── scripts/ # Setup and deployment scripts
- Node.js (v16+)
- PostgreSQL (v12+)
- npm or yarn
- Clone the repository
- Install dependencies:
npm install- Set up environment variables:
# In apps/api directory
cp .env.example .env
# Edit the .env file with your database credentials and JWT secret- Initialize the database:
cd apps/api
npm run db:migrate
npm run db:seed # Optional - adds sample dataStart all services in development mode:
npm run devOr start individual services:
# API only
npm run dev:api
# Web only
npm run dev:webBuild all packages and apps:
npm run buildDeploy using PM2:
npm run start:pm2The API endpoints are available at /api/v1 and include:
/api/v1/auth- Authentication/api/v1/users- User management/api/v1/expenses- Expense CRUD operations/api/v1/categories- Category management
MIT