Skip to content

Repository files navigation

x-app

X (Twitter) clone built with Next.js App Router, shadcn/ui, TanStack Query, and MongoDB.

Prerequisites

  • Node.js 20+
  • Docker (for local MongoDB)

Setup

npm install
cp .env.example .env.local
# set AUTH_SECRET to a long random string (openssl rand -base64 32)
npm run db:up
npm run dev

App: http://localhost:3000
MongoDB: mongodb://127.0.0.1:27017/x-app

Auth uses NextAuth (Auth.js) with JWT + credentials. Sign up at /signup, sign in at /login.

Scripts

Command Description
npm run dev Start Next.js dev server
npm run build Production build
npm run typecheck TypeScript check (tsc --noEmit)
npm run lint ESLint
npm run db:up Start MongoDB via Docker Compose
npm run db:down Stop MongoDB

License

MIT

x-app-next

About

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages