The Problem

A rideshare product touches mobile UI, live maps, auth, payments, and a database. Wiring those together by hand is a multi-week effort. This repository is the companion code to a JavaScript Mastery YouTube tutorial that demonstrates the full stack — React Native, Expo, PostgreSQL, Stripe, Google Maps, Clerk, and zustand — in one runnable app.

What This Does

It is an Expo React Native app using file-based routing. The app/ directory splits into three route groups: app/(auth)/ for sign-in/sign-up/welcome, app/(root)/ for the authenticated tabs (home, rides, chat, profile) plus the ride-booking flow (find-ride, book-ride, confirm-ride), and app/(api)/ for serverless API routes named with the Expo +api.ts convention. Those routes (user+api.ts, ride/create+api.ts, ride/[id]+api.ts, driver+api.ts, (stripe)/create+api.ts, (stripe)/pay+api.ts) handle backend work against serverless Postgres and Stripe.

components/ holds the reusable UI (Map, RideCard, DriverCard, Payment, OAuth, InputField, CustomButton). lib/ contains auth.ts, fetch.ts, map.ts, and utils.ts; store/index.ts is the zustand store; constants/index.ts defines shared values. Styling is Tailwind via tailwind.config.js.

How It Is Wired

The static import analysis resolved 45 internal modules but traced 0 import edges, so a precise call graph has not been mapped for this repository — the wiring below comes from the file structure, not a traced path.

Execution starts at app/index.tsx, which routes to the auth group. app/(auth)/welcome.tsx leads to sign-in.tsx / sign-up.tsx, which use components/OAuth.tsx and lib/auth.ts (Clerk) for authentication. Authenticated users land in app/(root)/(tabs)/home.tsx, which renders components/Map.tsx with live location and recent rides.

The booking flow is the core path: find-ride.tsx → book-ride.tsx → confirm-ride.tsx, ending in a Stripe payment through app/(api)/(stripe)/create+api.ts and pay+api.ts. On successful payment, app/(api)/ride/create+api.ts persists the ride. These API routes are the only files that touch external services (database, Stripe), so they carry the widest blast radius — a change to pay+api.ts affects every paid booking.

How To Use It

Setup requires npm install (a package-lock.json is present). Environment configuration is the missing piece: the README's Quick Start section is not included in the excerpt, so the exact env var names are not documented here — expect Expo public keys for Clerk, Google Maps, Stripe, and a Postgres connection string. Run with npx expo start from the repository root.

Code Health & Issues

Static analysis found 1 high-severity issue: duplicated code blocks — 30 repeated 6-line blocks across 6 files including app/(auth)/sign-in.tsx, app/(auth)/sign-up.tsx, app/(root)/(tabs)/home.tsx, and app/(root)/(tabs)/rides.tsx. The fix is extracting shared helpers.

SDLC gaps evident from the structure:

  • High — no test suite; 45 source files, zero test files.
  • High — no CI configuration; nothing builds or tests on push.
  • High — no LICENSE file; default all-rights-reserved applies.
  • Medium — no Dependabot/Renovate config for dependency updates.
  • Low — missing .editorconfig, .gitattributes, and formatter config.

The Bottom Line

This is a well-organized tutorial scaffold that demonstrates a realistic full-stack mobile architecture. It is reference material, not a production base — no tests, CI, or license means you should not ship it as-is. Use it to learn the Expo + serverless Postgres + Stripe pattern, then build your own on top.