- Node.js (v16 or higher)
- npm or yarn
- Firebase account (for backend services)
-
Install Dependencies
npm install
-
Configure Firebase
- Update
src/firebase/config.jswith your Firebase project credentials - Enable Phone Authentication in Firebase Console
- Set up Firestore database
- Update
-
Run Development Server
npm run dev
-
Build for Production
npm run build
react^19.2.0 - UI libraryreact-dom^19.2.0 - React DOM rendererreact-router-dom- Routing library (newly added)firebase^12.7.0 - Backend servicesvite-plugin-pwa^1.2.0 - PWA support
vite^7.2.4 - Build tooltailwindcss^3.4.13 - CSS frameworkeslint- Code lintingfirebase-tools- Firebase CLI
components/
โโโ onboarding/ # User onboarding flow
โโโ education/ # Learning modules
โโโ investment/ # Investment features
โโโ dashboard/ # Portfolio dashboard
โโโ common/ # Shared components
- AppContext - Global app state (user, language, settings)
- InvestmentContext - Portfolio and transactions
- EducationContext - Learning progress
/onboarding -> First-time user setup
/ -> Home/Dashboard (protected)
/invest -> Investment options (protected)
/learn -> Educational content (protected)
/passbook -> Transaction history (protected)
/profile -> User profile & settings (protected)
- Primary Green:
green-600(โน10 investment actions) - Accent: Various for trust indicators
- Background:
gray-50(light, low power consumption)
- Base Size: 14px (readable on small screens)
- Headings: Bold, clear hierarchy
- Body: Medium weight for readability
- Mobile-First: Designed for small screens (320px+)
- Bottom Navigation: Easy thumb access
- Card-Based: Clear content separation
- Development server configuration
- Build optimization for low-end devices
- PWA manifest settings
- Custom color palette
- Typography settings
- Responsive breakpoints
- Hosting rules
- Security rules for Firestore
- Function deployment settings
- Offline Support: Works without internet
- Install Prompt: Add to home screen
- Background Sync: Syncs when online
- Push Notifications: Investment updates
- Cache-first for static assets
- Network-first for dynamic data
- 5MB cache limit for low-end devices
- Phone number + OTP (Firebase Auth)
- No password storage
- Session management
- Encrypted data at rest (Firestore)
- HTTPS only
- API key restrictions
- Minimal data collection
- No third-party tracking
- GDPR compliant
- English (en)
- Hindi (hi) - เคนเคฟเคเคฆเฅ
- Bengali (bn) - เฆฌเฆพเฆเฆฒเฆพ
- Telugu (te) - เฐคเฑเฐฒเฑเฐเฑ
- Marathi (mr) - เคฎเคฐเคพเค เฅ
- Tamil (ta) - เฎคเฎฎเฎฟเฎดเฏ
- Add translations to language files
- Update
LanguageSelectorcomponent - Test all UI elements
- Update documentation
- Onboarding flow completion
- Phone authentication
- Investment creation
- Lesson completion
- Transaction history
- Offline functionality
- Language switching
- Low-end device performance
- Low-end Android (< 2GB RAM)
- Mid-range smartphone
- 2G/3G network
- WiFi
- Different screen sizes
- Initial load: < 300KB (gzipped)
- Total assets: < 1MB
- Lazy loading for routes
- Code splitting for components
- First Contentful Paint: < 2s
- Time to Interactive: < 3s
- 60fps animations
- < 100ms input response
- Image compression (WebP)
- Lazy loading images
- API request batching
- Offline queue for actions
npm run build
firebase deploy --only hostingCreate .env file:
VITE_FIREBASE_API_KEY=your_api_key
VITE_FIREBASE_AUTH_DOMAIN=your_domain
VITE_FIREBASE_PROJECT_ID=your_project_id
VITE_FIREBASE_STORAGE_BUCKET=your_bucket
VITE_FIREBASE_MESSAGING_SENDER_ID=your_sender_id
VITE_FIREBASE_APP_ID=your_app_id
- Update version number
- Run linter (
npm run lint) - Test on staging environment
- Check bundle size
- Test PWA install
- Verify Firebase rules
- Update documentation
- Create feature branch:
git checkout -b feature/name - Commit changes:
git commit -m "Description" - Push to remote:
git push origin feature/name - Create pull request
- Merge after review
- Follow ESLint rules
- Use functional components
- JSDoc comments for functions
- Meaningful variable names
- Keep components < 200 lines
- One component per file
- Props destructuring
- PropTypes or TypeScript
- Accessibility attributes
- Mobile-first design
Issue: Firebase auth not working
- Check Firebase console configuration
- Verify phone auth is enabled
- Check reCAPTCHA setup
Issue: Routing not working
- Ensure react-router-dom is installed
- Check Browser Router configuration
- Verify route paths
Issue: Context not updating
- Check Context Provider hierarchy
- Verify useContext import
- Check state update logic
Issue: Styles not applying
- Run
npm run devagain - Clear browser cache
- Check Tailwind config
- Fork the repository
- Create feature branch
- Make changes
- Write/update tests
- Submit pull request
For technical issues or questions:
- Create GitHub issue
- Email: support@microinvest.com
- Documentation:
/PROJECT_DOCUMENTATION.md
Built with โค๏ธ for India's First-Time Investors