A full-stack social media application built for real-time content sharing and interaction.
Note
App is hosted with free tier services, first load might take some time.
This was one of the first FullStack projects I created, it's purpose was to tie everything I learned from The Odin Project's course together in a relatively complex project. Social media apps are among the most widely used applications on the web today.
- Authentication with username/password AND Github Auth (cookies based).
- Real time interaction updates (posts, follow requests, comments, likes).
- Image sharing capability.
- User connection and interaction.
- Javascript
- React
- Vite
- Vercel
- Socket.IO
- Express
- Nodejs
- PostgreSQL
- Prisma ORM
- Socket.IO
- Cloudinary
- OnRender
- Neon
- Node.js
- npm
- PostgreSQL (ensure your database is running)
- Basic knowledge of using a terminal (steps are beginner-friendly)
git clone https://github.com/3antozz/Odin-Book
cd Odin-Bookcd api
npm installImportant
Github Authentification won't work unless you register a Github OAuth application and acquire your own tokens, set Authorization callback URL field to: http://localhost:3000/auth/github/callback. Others fields may be required but are not important.
1- Create a .env file in the api/ directory (based on .env.example) and fill in the required environment variables such as:
- Database connection URL
- Session secret
- Cloudinary credentials
- Github Tokens (if available)
Note
Cloudinary credentials are needed to upload images, else it's not possible.
2- Start the backend server:
npm startNote
The backend will run on http://localhost:3000 by default.
1- Open a new terminal window or tab:
cd client
npm install
npm run dev2- Rename the .env.example file to .env in the client/ directory
Note
The frontend will run on http://localhost:5173 by default.
1- Once both servers are running:
2- Visit http://localhost:5173 in your browser
- Lucide React β Import Icons.
- react-virtuoso β React component that displays large data sets using virtualized rendering (render when visible in viewport).
- Socket.IO β Low-latency, bidirectional and event-based communication between a client and a server for real time updates.
- date-fns β Used for manipulating JavaScript dates.
- bcryptjs β For securing passwords by hashing and salting.
- express-session β Simple session middleware for Authenticating.
- prisma/client β ORM - Auto-generated and type-safe query builder for Node.js.
- prisma-session-store β An express session store implementation for the Prisma ORM.
- passport β Express-compatible authentication middleware for Node.js.
- passport-local β This module lets you authenticate using a username and password in your Node.js applications.
- passport-github2 β This module lets you authenticate using GitHub OAuth 2.0 in your Node.js applications.
- express-validator β User input validation middleware.
- cloudinary β Images storage service integration.
- multer β Node.js middleware for handling multipart/form-data, used for uploading files.
- express-async-handler β Asynchronous exception-handling middleware.
- Socket.IO β Low-latency, bidirectional and event-based communication between a client and a server for real time updates.
- cors β Package for providing a Connect/Express middleware that can be used to enable CORS.





