Threads is a web application that allows users to participate in discussions, interact with communities, and customize their user profiles. It is built using Next.js, React, MongoDB, Tailwind CSS, and other technologies to create a seamless and user-friendly experience.
- User Authentication: Users can sign up and log in to the application using Clerk authentication.
- Create Threads: Users can create new discussion threads and start conversations within communities.
- Comments: Users can add comments to existing threads to contribute to the discussion.
- Community Interaction: Users can join communities and participate in discussions within those communities.
- User Profile: Users can customize their profiles, update their profile pictures, and provide a bio.
Before running the application, make sure you have the following installed:
- Node.js (v20 or higher)
- MongoDB
- Clone the repository:
git clone https://github.com/SudoKMaar/threads.git
cd threads-clone
- Install dependencies:
npm install
- Set up environment variables:
Create a .env.local
file in the root directory and add the required environment variables:
NEXT_PUBLIC_CLERK_PUBLISHABLE_KEY= Clerk's public key for client-side authentication.
CLERK_SECRET_KEY= Clerk's secret key for server-side authentication.
NEXT_PUBLIC_CLERK_SIGN_IN_URL= /sign-in
NEXT_PUBLIC_CLERK_SIGN_UP_URL= /sign-up
NEXT_PUBLIC_CLERK_AFTER_SIGN_IN_URL= /onboarding
NEXT_PUBLIC_CLERK_AFTER_SIGN_UP_URL= /
MONGODB_URL= MongoDB connection URL.
Replace keys with your actual Clerk public key, Clerk secret key, and MongoDB connection URL, respectively.
- Start the development server:
npm run dev
The application should now be running on http://localhost:3000
.
- Next.js: React framework with server-side rendering and static site generation capabilities.
- React: JavaScript library for building user interfaces.
- MongoDB: NoSQL database for storing application data.
- Mongoose: Object Data Modeling (ODM) library for MongoDB and Node.js.
- Tailwind CSS: Utility-first CSS framework for styling elements.
- Zod: TypeScript-first schema validation library.
- Clerk: Authentication and user management service.
- ESLint: Linter tool for identifying and fixing code errors.
- UploadThing: Library for handling file uploads.
Contributions to Threads Clone are welcome! To contribute, please follow these steps:
- Fork the repository.
- Create a new branch for your feature or bug fix.
- Make your changes and commit them.
- Push the changes to your fork.
- Submit a pull request to the
main
branch of the original repository.
This project is licensed under the MIT License.
- Clerk for providing authentication services.
- UploadThing for handling file uploads.
- Next.js for the excellent React framework.
- Tailwind CSS for the utility-first CSS framework.