Book My PG is a comprehensive mobile-first web application designed to help college students easily find and manage their PG accommodations near their college campus. The app provides features like property listings, price filters, wishlist management, and essential details for student life such as college info, transport, food, and essentials.
- Mobile-First Design: Optimized for smartphone usage
- 7 Core Sections: Home, College Info, Transport, PG Listings, Food, Essentials, Get In Touch (Contact), ❤️ (Wishlist)
- Interactive Navigation: Bottom navigation
- Real-time Search: Find PG accommodations with filtering
- Transport Guide: Bus routes, metro lines, and airport connectivity
- Food Discovery: Canteens, restaurants, and street food
- Emergency Contacts: Quick access to essential services
- Framework: Next.js 15 (App Router)
- Language: TypeScript
- Styling: Tailwind CSS
- Icons: Lucide React
- Deployment: Vercel
college-city-guide/
├── src/
│ ├── app/ # Next.js App Router
│ ├── components/
│ │ ├── ui/ # Reusable UI components
│ │ ├── sections/ # Page sections
│ │ ├── navigation/ # Navigation components
│ │ └── layout/ # Layout components
│ ├── hooks/ # Custom React hooks
│ ├── types/ # TypeScript type definitions
│ ├── data/ # Static data and constants
│ └── utils/ # Utility functions
- Node.js 18+
- Next.js 15
- npm or yarn
- Clone the repository
git clone https://github.com/arya-dev2005/book-my-pg.git
cd book-my-pg- Install dependencies
npm install
# or
yarn install- Run development server
npm run dev
# or
yarn dev- Open in browser
Navigate to you local browser. The app will be available at http://localhost:3000
- Build for Production
npm run build
npm startnpm install -g vercel
vercel --prod- Push code to GitHub/GitLab/Bitbucket
- Connect repository to Vercel
- Deploy automatically
No environment variables required for basic functionality.
- Primary Blue: #007BFF
- Gray Scale: #f8f9fa, #e9ecef, #6c757d, #333
- Success Green: #28a745
- Warning Orange: #fd7e14
- Danger Red: #dc3545
- Headings: font-bold
- Body: Regular weight
- Small Text: text-sm
- Grid System: 8px base unit
- Padding/Margin: Multiples of 4px (1, 2, 3, 4, 6, 8, 12, 16, 24, 32)
Card: Reusable container componentButton: Primary and secondary variantsInput: Form input with validationIconCard: Card with icon and description
Each section is a self-contained component:
HomeSection: Landing page with navigation cardsCollegeSection: College informationTransportSection: Transportation with accordionPGSection: PG listings with filteringFoodSection: Food and restaurantsEssentialsSection: Emergency and essential servicesContactSection: Contact form with validationWishlistSection: Wishlist to save favourite PGs.
useActiveSection: Manages current section stateuseAccordion: Handles accordion expand/collapseuseWishlist: Manages wishlist
- Touch-friendly button sizes (minimum 44px)
- Responsive grid layouts
- Fixed navigation for easy access
- Optimized for iOS and Android browsers
- Fast loading with Next.js optimization
- Create component in
/components/sections/ - Add section constant to
/data/constants.ts - Update navigation arrays
- Register component in main page
- Modify
/tailwind.config.jsfor theme changes - Update
/app/globals.cssfor global styles - Component-specific styles in respective files
- Build Errors: Check TypeScript types
- Styling Issues: Verify Tailwind classes
- Navigation Not Working: Check section constants
- Images are optimized with Next.js Image component
- Code splitting enabled by default
- CSS is automatically purged in production
- Fork the repository
- Create feature branch (
git checkout -b feature/amazing-feature) - Commit changes (
git commit -m 'Add amazing feature') - Push to branch (
git push origin feature/amazing-feature) - Open Pull Request
This project is licensed under the MIT License.
For support, email support@bookmypg.co.in or create an issue in the repository.
Made with ❤️ for students by students