A modern, feature-rich Discord clone built with Next.js, TypeScript, and shadcn/ui components. This project aims to replicate the core functionality and sleek design of Discord while showcasing the power of Next.js and related technologies.
Clone the repository:
git clone https://github.com/meharsulaiman/discord-clone.git
cd discord-clone
Install dependencies:
npm install
# or
yarn install
Set up environment variables:
Create a .env
file in the root directory and add the necessary environment variables. Use the following .env.example
as a template:
NEXT_PUBLIC_CLERK_PUBLISHABLE_KEY=
CLERK_SECRET_KEY=
NEXT_PUBLIC_CLERK_SIGN_IN_URL=/sign-in
NEXT_PUBLIC_CLERK_SIGN_UP_URL=/sign-up
NEXT_PUBLIC_CLERK_AFTER_SIGN_IN_URL=/
NEXT_PUBLIC_CLERK_AFTER_SIGN_UP_URL=/
DATABASE_URL=""
UPLOADTHING_SECRET=''
UPLOADTHING_APP_ID=''
Make sure to fill in the values for each variable:
DATABASE_URL
Set up the database:
npx prisma generate
npx prisma db push
Run the development server:
npm run dev
# or
yarn dev
Open http://localhost:3000 in your browser to see the result.
npm run dev
or yarn dev
: Starts the development servernpm run build
or yarn build
: Builds the app for productionnpm start
or yarn start
: Runs the built app in production modenpm run lint
or yarn lint
: Runs the linter to check for code quality issuesContributions are welcome! Please feel free to submit a Pull Request.
This project is open source and available under the MIT License.