turbo-expo-nextjs-clerk-convex-monorepo  by get-convex

Fullstack monorepo template for AI-enhanced web and native apps

Created 1 year ago
289 stars

Top 91.0% on SourcePulse

GitHubView on GitHub
Project Summary

A modern TypeScript monorepo template for building AI-powered web and native applications. It targets developers seeking a unified, type-safe full-stack development experience, integrating Turborepo for monorepo management, Next.js for web, Expo for native, Convex for backend services and database, and Clerk for authentication. The primary benefit is accelerated development with end-to-end type safety and real-time capabilities out-of-the-box.

How It Works

This project employs Turborepo to manage a monorepo containing a Next.js 15 web application, a React Native Expo mobile application, and a Convex backend. It emphasizes end-to-end TypeScript, ensuring type consistency from database schema definitions to frontend API clients. Convex provides a hosted backend with a reactive database and server functions, enabling real-time data updates via client-side hooks. User authentication is handled by Clerk, with optional integration for OpenAI to provide AI-driven text summarization features.

Quick Start & Requirements

  • Installation: Ensure Yarn is installed (npm install -g yarn), then run yarn to install project dependencies.
  • Configuration:
    • Execute npm run setup --workspace packages/backend to configure Convex, which involves logging in and creating a free Convex project. This step requires setting environment variables in the Convex dashboard.
    • Configure Clerk following their guide and add the CLERK_ISSUER_URL to your Convex environment variables. Enable Google and Apple social connections in Clerk for React Native login.
    • Optionally, add your OPENAI_API_KEY to Convex environment variables for AI summarization.
    • Create .env.local files in apps/web and apps/native based on .example.env templates, populating them with your Convex and Clerk environment variables.
  • Running: Use npm run dev to launch both the web and mobile applications simultaneously. Logs for each component can be viewed separately or unified by adjusting turbo.json.
  • Prerequisites: Yarn, a Convex account, a Clerk account, and an OpenAI API key (optional).

Highlighted Details

  • Achieves end-to-end type safety from database schema definitions to frontend API clients.
  • Leverages Convex for real-time data synchronization across the application by default.
  • Includes an example note-taking application demonstrating AI summarization via OpenAI.
  • Provides a unified backend API serving both web and native applications.
  • Offers a deployment command (npx convex deploy) that builds both the frontend and the Convex backend, configured for Vercel.

Maintenance & Community

No specific details regarding contributors, sponsorships, or community channels (e.g., Discord, Slack) were provided in the README content.

Licensing & Compatibility

The license type for this repository is not specified in the provided README content.

Limitations & Caveats

The initial setup command (npm run setup) is explicitly mentioned to produce an error and necessitate manual configuration of environment variables within the Convex dashboard before it can successfully complete.

Health Check
Last Commit

2 days ago

Responsiveness

Inactive

Pull Requests (30d)
1
Issues (30d)
0
Star History
37 stars in the last 30 days

Explore Similar Projects

Feedback? Help us improve.