A personal full-stack portfolio website built with React, Vite, Node.js, Express, and MongoDB. The frontend presents portfolio information, projects, skills, and a contact form. The backend provides API endpoints for fetching projects and saving contact messages.
- Single-page React frontend
- Client-side routing with React Router
- Responsive portfolio layout
- Dynamic projects page with backend fetching
- Fallback project data when the backend is unavailable
- Contact form with backend submission
- Express API with MongoDB models
- Clean component-based frontend structure
- React
- Vite
- React Router DOM
- JavaScript
- CSS
- Node.js
- Express.js
- MongoDB
- Mongoose
- CORS
- dotenv
Portfolio_Neel/
Frontend/
my-react-app/
src/
components/
Navbar.jsx
Footer.jsx
ProjectCard.jsx
SkillBadge.jsx
pages/
HomePage.jsx
ProjectsPage.jsx
ContactPage.jsx
App.jsx
main.jsx
index.css
package.json
vite.config.js
backend/
config/
db.js
controllers/
contactControllers.js
projectControllers.js
models/
Contact.js
Projects.js
routes/
contactRoutes.js
projectRoutes.js
server.js
package.jsonThe frontend is a Vite React app. main.jsx renders the root App component. App.jsx sets up routing and keeps shared layout components such as the navbar and footer visible across pages.
Main routes:
/ Home page
/projects Projects page
/contact Contact pageImportant frontend concepts used:
- Functional components
- Props
useStateuseEffect- Controlled forms
- Conditional rendering
- List rendering with
.map() - Environment variables
- API calls using
fetch
The backend is an Express server connected to MongoDB using Mongoose.
API routes:
GET /project Fetch all projects
POST /contact Save a contact messageThe backend starts from:
backend/server.jsMake sure you have these installed:
- Node.js
- npm
- MongoDB connection string
Clone the repository:
git clone https://github.com/DuttaNeel07/Portfolio_Neel.git
cd Portfolio_NeelInstall backend dependencies:
cd backend
npm installInstall frontend dependencies:
cd ../Frontend/my-react-app
npm installCreate a .env file inside the backend folder:
MONGO_URI=your_mongodb_connection_string
PORT=10000Create a .env file inside Frontend/my-react-app:
VITE_API_URL=http://localhost:10000Start the backend:
cd backend
npm startStart the frontend:
cd Frontend/my-react-app
npm run devThe frontend will usually run at:
http://localhost:5173The backend will run at:
http://localhost:10000To create a production build:
cd Frontend/my-react-app
npm run buildTo preview the production build locally:
npm run previewGET /projectReturns all projects stored in MongoDB.
POST /contactRequest body:
{
"name": "Your Name",
"message": "Your message"
}If name is not provided, the backend stores it as Anonymous.
This project is a full-stack portfolio application. The frontend is built using React and Vite, with React Router handling navigation between pages. Reusable components such as Navbar, Footer, ProjectCard, and SkillBadge keep the UI modular. The Projects page uses useEffect to fetch project data from the backend, while the Contact page uses controlled form inputs and sends a POST request to the backend. The backend is built with Express and MongoDB, providing routes for project data and contact form submissions.
Neel Dutta
- GitHub: DuttaNeel07
- LinkedIn: engineel
- Email: neel.dutta0729@gmail.com