A monorepo containing the Partner Platform backend API, dashboard frontend, and shared validation library.
- @partner-platform/backend - Express.js REST API server
- @partner-platform/dashboard - React + Vite frontend application
- @partner-platform/shared-validation - Shared Zod validation schemas
- Node.js >= 18.0.0
- npm >= 9.0.0
Clone the repository and install all dependencies:
cd partner-platform
npm installThis will install dependencies for all workspace packages.
# Run all services in development mode (backend + dashboard)
npm run dev
# Run backend only
npm run dev:backend
# Run dashboard only
npm run dev:dashboard
# Run backend worker (Temporal)
npm run worker:dev# Build all packages
npm run build
# Build backend
npm run build:backend
# Build dashboard
npm run build:dashboard# Start backend server
npm run start:backend
# Start dashboard
npm run start:dashboard# Run tests in all packages
npm run test
# Lint all packages
npm run lint
# Fix linting issues
npm run lint:fix# Clean all node_modules
npm run clean:modules
# Clean build artifacts and node_modules
npm run cleanpartner-platform/
├── packages/
│ ├── backend/ # Express.js API
│ │ ├── src/
│ │ ├── migrations/
│ │ ├── server.js
│ │ └── package.json
│ ├── dashboard/ # React + Vite frontend
│ │ ├── src/
│ │ ├── public/
│ │ ├── index.html
│ │ └── package.json
│ └── shared-validation/ # Shared validation schemas
│ ├── schemas/
│ ├── config/
│ ├── index.js
│ └── package.json
├── .gitignore
├── .prettierrc
├── .eslintrc.json
├── package.json # Root workspace configuration
└── README.md
Express.js REST API with:
- Authentication (Google OAuth, Microsoft OAuth)
- Database (PostgreSQL with Sequelize)
- Background jobs (BullMQ + Redis)
- Temporal workflows
- API documentation (Swagger)
Development:
cd packages/backend
npm run devEnvironment Variables:
Copy prod.env to .env and configure required variables.
React + Vite single-page application with:
- React Router for routing
- Redux Toolkit for state management
- Radix UI components
- Tailwind CSS for styling
- React Hook Form with Zod validation
Development:
cd packages/dashboard
npm run devBuild:
cd packages/dashboard
npm run buildCentralized Zod validation schemas shared between backend and dashboard:
- Property listing schemas
- Step configuration
- Reusable validation utilities
Usage in packages:
// Backend (CommonJS)
const { schemas, stepConfig } = require('@partner-platform/shared-validation');
// Dashboard (ESM) - Note: May need to update to ESM exports
import { schemas, stepConfig } from '@partner-platform/shared-validation';The monorepo uses npm workspaces to manage inter-package dependencies. The shared-validation package is referenced using the workspace protocol (*), which automatically links to the local version.
- Make changes in any package
- Test locally using
npm run dev - Lint code with
npm run lint - Build with
npm run build - Commit changes and push
This monorepo structure provides:
- ✅ Unified version control
- ✅ Simplified dependency management
- ✅ Easier refactoring across packages
- ✅ Consistent tooling and scripts
- ✅ Atomic commits across packages
To migrate your existing code into this structure:
- Backend: Copy all files from
partner-platform-backendtopackages/backend/ - Dashboard: Copy all files from
partner-platform-dashboardtopackages/dashboard/ - Shared Validation: Copy all files from
shared-validationtopackages/shared-validation/ - Install dependencies: Run
npm installfrom root - Update imports: Ensure all imports reference
@partner-platform/shared-validation
Each package has its own environment configuration:
packages/backend/.env- Backend environment variablespackages/dashboard/.env- Dashboard environment variables
- Create a feature branch
- Make changes in relevant package(s)
- Test thoroughly
- Submit a pull request
ISC