Mustang Market Mobile
React Native (Expo) app for Mustang Market - Cal Poly's student marketplace.
Features
- š± Native iOS & Android apps
- š Cal Poly email authentication
- šļø Browse and search listings
- š¾ Save/bookmark listings
- š¤ User profiles with ratings
- š Multiple listing types (Products, Services, Rideshare, Housing)
Tech Stack
- Expo (SDK 54) - React Native framework
- Expo Router - File-based navigation
- Firebase - Auth, Firestore, Storage
- NativeWind - Tailwind CSS for React Native
Getting Started
Prerequisites
- Node.js 18+
- npm or yarn
- Expo Go app on your phone (for development)
Installation
-
Clone this repository
-
Install dependencies:
npm install -
Create your environment file:
cp .env.example .env -
Fill in your Firebase credentials in
.env -
Start the development server:
npx expo start -
Scan the QR code with Expo Go (Android) or Camera app (iOS)
Project Structure
āāā app/ # Expo Router screens
ā āāā (tabs)/ # Tab navigation
ā ā āāā index.tsx # Browse/Home
ā ā āāā messages.tsx # Messages
ā ā āāā create.tsx # Create listing
ā ā āāā saved.tsx # Saved listings
ā ā āāā profile.tsx # User profile
ā āāā listing/[id].tsx # Listing detail
ā āāā login.tsx # Authentication
ā āāā _layout.tsx # Root layout
āāā src/
ā āāā components/ # Reusable components
ā āāā contexts/ # React contexts (Auth)
ā āāā lib/ # Firebase, types, utilities
ā āāā constants/ # App constants
āāā assets/ # Images, fonts
āāā app.json # Expo config
Firebase Setup
This app shares the same Firebase backend as the web app. Make sure your Firebase project has:
- Authentication enabled with Email/Password provider
- Firestore with the following collections:
listingsuserssavedListingsconversationsrequests
- Storage bucket for images
- Appropriate security rules
Building for Production
Development Build
npx expo run:ios
npx expo run:android
Production Build (EAS)
npm install -g eas-cli
eas build --platform all
Contributing
- Fork the repository
- Create a feature branch
- Make your changes
- Submit a pull request
License
MIT
š Mustang Market
Mobile Repository
The Secure, Exclusive Marketplace for the Cal Poly Community.
Mustang Market is a peer-to-peer marketplace designed specifically for Cal Poly students. It eliminates the "sketchiness" of public marketplaces by requiring @calpoly.edu verification and using a Digital Handshake (QR Scan) to ensure safe, guaranteed transactions.
š Tech Stack
- Frontend: Next.js 14+ (App Router), Tailwind CSS, TypeScript
- Backend/Auth: Firebase (Firestore, Authentication, Storage)
- Payments: Stripe Connect (Express) for Escrow & Payouts
- Mobile: Currently PWA (Progressive Web APP) but eventually moving to React Native / Expo on mustang-market-mobile
ā” The "Easy" User Flow (MVP)
- List (Seller)
- Student uploads item photos, description, and price.
- Listing is tagged by campus location (e.g., PCV, Red Bricks, Yosemite).
- Secure (Buyer)
- Buyer clicks "Secure Purchase" and pays via the app.
- The Vault: Funds are held in escrow by the platform.
- A private chat opens after the buyer pays for the Buyer and Seller to coordinate a meetup.
- Exchange (The Handshake)
- Parties meet at agreed upon location.
- Buyer inspects the item.
- The Trigger: Seller shows a unique QR code -> Buyer scans it in-app.
- Payout
- The scan confirms the item was received.
- Split: 95% to Seller / 5% Service Fee to Mustang Market.
š Safety & Trust Guardrails
- Edu-Only: Firebase Auth rules strictly block any email not ending in @calpoly.edu.
- Escrow: Sellers are never "ghosted" without payment, and Buyers never pay for a broken item.
- Reputation: Every transaction builds a "Campus Trust Score" visible on user profiles.
š Getting Started
- Clone & Install:
Bashgit clone https://github.com/your-repo/mustang-market.git
npm install
45: 2. Environment Variables: Create a .env.local with your Firebase and Stripe keys.
# Firebase Config
NEXT_PUBLIC_FIREBASE_API_KEY=...
NEXT_PUBLIC_FIREBASE_PROJECT_ID=...
# Stripe Config
NEXT_PUBLIC_STRIPE_PUBLISHABLE_KEY=pk_test_...
STRIPE_SECRET_KEY=sk_test_...
STRIPE_WEBHOOK_SECRET=whsec_...
STRIPE_PLATFORM_FEE_PERCENT=10
- Run Development:
npm run dev
š Monetization Strategy
- Service Fee: A 5% "Trust & Protection" fee on all digital transactions.
ideas for later:
- Mustang Boost: $1.99 to pin a listing to the top of the feed for 24 hours.
- Sponsored Posts: Local SLO businesses (coffee shops, bike repair) promoting to students.
See docs.md for more documentation!
License Summary
This repository is proprietary and not open source.
- Ownership is retained exclusively by the original Mustang Market founders
- Source code access is permitted for academic review only
- Modification, redistribution, deployment, or commercial use is prohibited
- No affiliation with Cal Poly is claimed or implied
See LICENSE.md for the full, legally binding terms.