This repo contains a modified version of create-t3-app including:
- GraphQL instead of trpc
- Google Auth Provider instead of Discord Auth Provider
- Supabase setup with Prisma
Follow this YouTube video to configure Supabase with the template.
- Docker
- NVM
brew install nvm - Node v18
nvm install v18
npm install
npx supabase start
npx prisma migrate dev # or npx prisma db push
npm run devRun integration tests against a dockerized supabase with:
npm run test-e2e
The GraphQL API uses type-graphql and runs on the NextJS server on Vercel as a serverless function.
The API is available locally at: http://localhost:3000/api/graphql
New GraphQL types and resolvers should be added in /src/server/graphql.
Generate GraphQL typescript types with:
npm run generate
Navigate to http://localhost:3000/users to see an example response from the GraphQL server.
The project uses Supabase as a hosted Postgres database.
First time login:
npx supabase login
Make sure Docker is running and start Supabase:
npx supabase start
And view the local supabase instance at: http://localhost:54323
Shutdown the database:
npx supabase stop
A Google OAuth client has been created at https://console.cloud.google.com/apis/credentials with authorized callback URLs:
http://localhost:3000/api/auth/callback/googlehttps://{APP_NAME}.vercel.app/api/auth/callback/google