A production-grade fullstack application built with Expo, Clerk, Stripe, PostgreSQL, and Express.js using a Turbo monorepo structure.
- Authentication: Clerk integration with Google OAuth and email/password
- UI/UX: Glassmorphic design with smooth animations and haptics
- Navigation: Drawer navigation with bottom sheet settings
- State Management: React Context API for auth state
- Components: Reusable UI components with TypeScript
- Database: PostgreSQL with Prisma ORM
- Authentication: Clerk middleware for token verification
- Subscriptions: Stripe integration with promo codes
- API: RESTful endpoints with TypeScript
- Webhooks: Stripe webhook handling
fullstack-app/
βββ apps/
β βββ mobile/ # Expo React Native app
β βββ backend/ # Express.js API server
βββ packages/
β βββ types/ # Shared TypeScript types
β βββ ui/ # Shared UI components (future)
βββ turbo.json # Turbo configuration
- Expo - React Native development platform
- Clerk - Authentication service
- Stripe - Payment processing
- React Navigation - Navigation library
- Reanimated - Animation library
- Gesture Handler - Touch handling
- Express.js - Web framework
- Prisma - Database ORM
- PostgreSQL - Database
- Stripe - Payment processing
- Clerk - Authentication verification
- Node.js 18+
- PostgreSQL
- Expo CLI
- Turbo CLI
-
Clone the repository
git clone <repository-url> cd fullstack-app
-
Install dependencies
npm install
-
Set up environment variables
Backend (
.env):cp apps/backend/.env.example apps/backend/.env # Edit with your actual valuesMobile (
.env):cp apps/mobile/.env.example apps/mobile/.env # Edit with your actual values -
Set up the database
cd apps/backend npx prisma generate npx prisma db push -
Start development servers
# From root directory npm run dev
# Root level
npm run dev # Start all apps in development
npm run build # Build all apps
npm run lint # Lint all apps
npm run type-check # Type check all apps
# Backend
cd apps/backend
npm run dev # Start backend server
npm run db:generate # Generate Prisma client
npm run db:push # Push schema to database
npm run db:studio # Open Prisma Studio
# Mobile
cd apps/mobile
npm start # Start Expo development server
npm run android # Run on Android
npm run ios # Run on iOSDATABASE_URL: PostgreSQL connection stringCLERK_JWT_KEY: Clerk JWT verification keySTRIPE_SECRET_KEY: Stripe secret keySTRIPE_WEBHOOK_SECRET: Stripe webhook secretFRONTEND_URL: Frontend URL for CORSPORT: Server port (default: 3001)
EXPO_PUBLIC_CLERK_PUBLISHABLE_KEY: Clerk publishable keyEXPO_PUBLIC_API_URL: Backend API URL
- User signs in/up with Clerk
- Clerk token is stored in AsyncStorage
- Token is sent to backend for user sync
- User profile is stored in local database
- App shows authenticated or unauthenticated routes
- Button: Glassmorphic button with haptics
- Card: Glassmorphic card component
- BottomSheetWrapper: Reusable bottom sheet
- Navigation: Drawer + stack navigation
- Login/SignUp: Clerk authentication
- Home: Dashboard with user info
- Settings: Bottom sheet with user preferences
- Subscription: Stripe subscription management
GET /auth/sync- Sync user with database
GET /subscriptions/products- Get Stripe productsPOST /subscriptions/create- Create checkout sessionGET /subscriptions/status- Get user subscriptionPOST /subscriptions/validate-promo- Validate promo code
POST /webhooks/stripe- Stripe webhook handler
- User: User profiles with subscription status
- Subscription: Stripe subscription data
- PromoCode: Promotional codes with usage tracking
- PromoCodeRedemption: Redemption tracking
- JWT token verification with Clerk
- CORS configuration
- Helmet security headers
- Input validation with Zod
- Secure token storage with AsyncStorage
- Glassmorphic design with transparency
- Smooth animations with Reanimated
- Haptic feedback on interactions
- Dark mode support
- Responsive design
- Loading states and error handling
- Set up PostgreSQL database
- Configure environment variables
- Run Prisma migrations
- Deploy to your preferred platform
- Configure Expo build settings
- Set up environment variables
- Build with EAS or Expo CLI
- Deploy to app stores
- Fork the repository
- Create a feature branch
- Make your changes
- Add tests if applicable
- Submit a pull request
This project is licensed under the MIT License.
For support, please open an issue in the repository or contact the development team.