Empowering communities through blood donation and fundraising campaigns. Together, we can make a difference and save lives.
- Overview
- Features
- Tech Stack
- Getting Started
- Project Structure
- Environment Variables
- Available Scripts
- Mobile Responsive
- API Documentation
- Contributing
- License
- Contact
Camply is a modern, full-stack campaign management platform that enables users to create, manage, and track both blood donation and fundraising campaigns. Built with React, TypeScript, and Node.js, it provides a seamless experience for campaign creators and donors alike.
- π©Έ Blood Donation Campaigns - Organize and track blood donation drives
- π° Fundraising Campaigns - Create and manage fundraising initiatives
- π Real-time Analytics - Track campaign performance with detailed insights
- π¨ Modern UI/UX - Beautiful, intuitive interface with dark mode support
- π± Fully Responsive - Optimized for mobile, tablet, and desktop
- π€ AI-Powered - Smart content suggestions using Google Gemini AI
- π Secure Authentication - JWT-based auth with Google OAuth support
- π― Progress Tracking - Real-time updates on campaign goals
- β Create blood donation and fundraising campaigns
- β Upload campaign images with URL validation
- β Set goals and track progress in real-time
- β Edit campaign details with full history tracking
- β Toggle campaign visibility (public/private)
- β Delete campaigns with confirmation
- β User registration and authentication
- β Google OAuth integration
- β Personal dashboard with campaign overview
- β Campaign analytics and insights
- β Profile management
- β Dark/Light theme toggle
- β AI-powered writing assistant for campaign descriptions
- β Image gallery for campaigns
- β Campaign edit history tracking
- β Progress update system
- β Campaign statistics and counters
- β Most visited campaigns showcase
- β Testimonial carousel
- β Responsive design for all devices
- β Campaign performance metrics
- β View count tracking
- β Donation/contribution tracking
- β Time-based filtering (7 days, 30 days, all time)
- β Campaign type filtering
- β Visual charts and graphs
- React 18.3.1 - UI library
- TypeScript 5.5.3 - Type safety
- Vite 5.4.2 - Build tool
- React Router 6.26.1 - Routing
- Framer Motion 11.5.4 - Animations
- React Icons 5.3.0 - Icon library
- Recharts 2.12.7 - Charts and graphs
- Node.js 20+ - Runtime
- Express 4.19.2 - Web framework
- PostgreSQL - Database
- Drizzle ORM 0.33.0 - Database ORM
- JWT - Authentication
- Bcrypt - Password hashing
- Google Gemini AI - Content generation
- Google OAuth 2.0 - Social authentication
- ESLint - Code linting
- Prettier - Code formatting
- TypeScript - Type checking
- Vite - Hot module replacement
- Node.js 20 or higher
- PostgreSQL 14 or higher
- npm or yarn package manager
- Google OAuth credentials (optional)
- Google Gemini API key (optional)
- Clone the repository
git clone https://github.com/perashaniD/camply.git
cd camply- Install dependencies
# Install frontend dependencies
npm install
# Install backend dependencies
cd server
npm install
cd ..- Set up environment variables
Create .env file in the root directory:
VITE_API_URL=http://localhost:3000
VITE_GOOGLE_CLIENT_ID=your_google_client_id
VITE_GEMINI_API_KEY=your_gemini_api_keyCreate server/.env file:
DATABASE_URL=postgresql://user:password@localhost:5432/camply
JWT_SECRET=your_jwt_secret_key
GOOGLE_CLIENT_ID=your_google_client_id
GOOGLE_CLIENT_SECRET=your_google_client_secret
PORT=3000- Set up the database
cd server
npm run db:push
npm run db:seed
cd ..- Start the development servers
In one terminal (backend):
cd server
npm run devIn another terminal (frontend):
npm run dev- Open your browser
http://localhost:5173
For testing purposes, you can use:
- Email: demo@example.com
- Password: demo123
camply/
βββ src/ # Frontend source code
β βββ components/ # React components
β β βββ Header.tsx # Navigation header
β β βββ Footer.tsx # Footer component
β β βββ CampaignCard.tsx # Campaign card component
β β βββ AIWritingAssistant.tsx
β β βββ ...
β βββ pages/ # Page components
β β βββ HomePage.tsx # Landing page
β β βββ Dashboard.tsx # User dashboard
β β βββ CampaignDetails.tsx # Campaign details
β β βββ ...
β βββ contexts/ # React contexts
β β βββ AuthContext.tsx # Authentication context
β β βββ ThemeContext.tsx # Theme context
β βββ services/ # API services
β β βββ api.ts # API client
β β βββ gemini.ts # AI service
β βββ styles/ # Global styles
β β βββ themes.css # Theme variables
β β βββ responsive.css # Responsive styles
β β βββ ...
β βββ utils/ # Utility functions
βββ server/ # Backend source code
β βββ src/
β β βββ routes/ # API routes
β β β βββ auth.ts # Authentication routes
β β β βββ campaigns.ts # Campaign routes
β β βββ db/ # Database
β β β βββ schema.ts # Database schema
β β β βββ seed.ts # Seed data
β β β βββ migrate.ts # Migrations
β β βββ index.ts # Server entry point
β βββ package.json
βββ public/ # Static assets
βββ index.html # HTML template
βββ package.json # Frontend dependencies
βββ tsconfig.json # TypeScript config
βββ vite.config.ts # Vite config
βββ README.md # This file
| Variable | Description | Required |
|---|---|---|
VITE_API_URL |
Backend API URL | Yes |
VITE_GOOGLE_CLIENT_ID |
Google OAuth Client ID | No |
VITE_GEMINI_API_KEY |
Google Gemini API Key | No |
| Variable | Description | Required |
|---|---|---|
DATABASE_URL |
PostgreSQL connection string | Yes |
JWT_SECRET |
Secret key for JWT tokens | Yes |
GOOGLE_CLIENT_ID |
Google OAuth Client ID | No |
GOOGLE_CLIENT_SECRET |
Google OAuth Client Secret | No |
PORT |
Server port (default: 3000) | No |
npm run dev # Start development server
npm run build # Build for production
npm run preview # Preview production build
npm run lint # Run ESLintnpm run dev # Start development server with nodemon
npm run build # Build TypeScript
npm run start # Start production server
npm run db:push # Push database schema
npm run db:seed # Seed database with sample data
npm run db:studio # Open Drizzle StudioCamply is fully responsive and optimized for all devices:
- β Mobile phones (320px - 768px)
- β Tablets (769px - 1024px)
- β Desktops (1025px+)
- β Portrait and landscape orientations
- β Touch-friendly interactions
- β Optimized for iOS Safari and Android Chrome
- Hamburger menu navigation
- Touch-friendly buttons (44x44px minimum)
- Responsive images and layouts
- Optimized forms for mobile input
- Fixed viewport height issues
- Prevented zoom on input focus
- Smooth scrolling and animations
For detailed mobile implementation, see MOBILE_RESPONSIVE_GUIDE.md
POST /api/auth/register # Register new user
POST /api/auth/login # Login user
POST /api/auth/google # Google OAuth login
GET /api/auth/me # Get current user
GET /api/campaigns # Get all campaigns
GET /api/campaigns/:id # Get campaign by ID
POST /api/campaigns # Create campaign
PUT /api/campaigns/:id # Update campaign
DELETE /api/campaigns/:id # Delete campaign
PATCH /api/campaigns/:id/visibility # Toggle visibility
POST /api/campaigns/:id/progress # Update progress
GET /api/campaigns/:id/history # Get edit history
GET /api/analytics/stats # Get overall statistics
GET /api/analytics/campaigns # Get campaign analytics
Contributions are welcome! Please follow these steps:
- Fork the repository
- Create a feature branch (
git checkout -b feature/AmazingFeature) - Commit your changes (
git commit -m 'Add some AmazingFeature') - Push to the branch (
git push origin feature/AmazingFeature) - Open a Pull Request
- Follow the existing code style
- Write meaningful commit messages
- Add tests for new features
- Update documentation as needed
- Ensure all tests pass before submitting PR
This project is licensed under the MIT License - see the LICENSE file for details.
Shanid Sajjatuz Islam
- π§ Email: shanidsajjatuz@gmail.com
- πΌ LinkedIn: linkedin.com/in/shanid-sajjatuz-islam
- π GitHub: github.com/perashaniD
- React - UI library
- Vite - Build tool
- Framer Motion - Animation library
- Google Gemini - AI content generation
- Drizzle ORM - Database ORM
- Unsplash - Stock images
- Email notifications
- Payment gateway integration
- Social media sharing
- Campaign comments and reviews
- Advanced search and filters
- Multi-language support
- PWA support
- Mobile app (React Native)
- Campaign categories and tags
- User verification system
This project is actively maintained and under continuous development. Feel free to report issues or suggest new features!
Made with β€οΈ by Shanid Sajjatuz Islam
β Star this repo if you find it helpful!