A web application that allows users to log in with Google, vote on their favorite comedy sketches, and view rankings based on Elo ratings.
This project is built using the T3 stack, which includes Next.js, TypeScript, Prisma, tRPC, and Tailwind CSS. The goal is to provide an engaging platform where users can rank comedy sketches by voting on pairs, with an Elo rating system determining the rankings.
Clone the repository:
git clone https://github.com/Confiqure/sketch-ranker.git
cd sketch-ranker
Install dependencies:
npm install
Set up environment variables:
Create a .env
file in the root directory and add the following environment variables:
DATABASE_URL=postgresql://USER:PASSWORD@HOST:PORT/DATABASE
GOOGLE_CLIENT_ID=your-google-client-id
GOOGLE_CLIENT_SECRET=your-google-client-secret
Initialize Prisma:
Run the following commands to set up your database schema:
npx prisma migrate dev
npx prisma generate
Load seed data:
Run the following command to load seed data into your database:
npm run seed
Start the development server:
npm run dev
http://localhost:3000
.Test Authentication:
http://localhost:3000/profile
and sign in with Google.Verify Database Integration:
Check that user information is stored in your PostgreSQL database after signing in:
npx prisma studio
Build the project:
npm run build
Start the production server:
npm start
http://localhost:3000
.The project is set up for deployment on AWS Amplify. To deploy:
Contributions are welcome! Please open an issue or submit a pull request.
This project is licensed under the MIT License.