The Task Manager is a full-stack web application designed to help users manage their tasks efficiently. It allows users to create, update, delete, and view tasks. The application also supports user authentication and provides a responsive user interface with light and dark mode themes.
- User authentication (register, login, and logout)
- Create, update, delete, and view tasks
- Filter and sort tasks by status, priority, and search query
- Responsive design with light and dark mode
- Secure API with JWT-based authentication
- React
- React Router
- Tailwind CSS
- DaisyUI
- Axios
- Day.js
- Node.js
- Express.js
- MongoDB (Mongoose)
- JSON Web Tokens (JWT)
- bcrypt.js
backend/
index.js
package.json
config/
config.js
controllers/
taskController.js
userController.js
middleware/
authMiddleware.js
models/
taskModel.js
User.js
routes/
taskRoutes.js
userRoutes.js
frontend/
package.json
README.md
public/
index.html
_redirects
src/
App.jsx
App.css
components/
Footer.jsx
LoginForm.jsx
RegisterForm.jsx
TaskForm.jsx
TaskList.jsx
ThemeToggle.jsx
navbar.jsx
context/
ThemeContext.jsx
pages/
About.jsx
FAQs.jsx
Privacy.jsx
Profile.jsx
Terms.jsx
services/
taskService.jsx
utils/
authUtils.jsx
- Node.js
- MongoDB
- Navigate to the
backenddirectory:cd backend - Install dependencies:
npm install
- Create a
.envfile in thebackenddirectory and add the following:PORT=5000 MONGO_URI=<your_mongo_connection_string> JWT_SECRET=<your_jwt_secret> JWT_EXPIRATION=1h
- Start the backend server:
npm run dev
- Navigate to the
frontenddirectory:cd frontend - Install dependencies:
npm install
- Create a
.envfile in thefrontenddirectory and add the following:REACT_APP_API_URL=http://localhost:5000
- Start the frontend development server:
npm start
The backend can be deployed to platforms like Render or Heroku. Ensure the environment variables are set correctly on the deployment platform.
The frontend can be deployed to platforms like Netlify or Vercel. Ensure the REACT_APP_API_URL points to the deployed backend URL.
POST /api/users/register- Register a new userPOST /api/users/login- Login a userGET /api/users/me- Get the logged-in user's profile
POST /api/tasks- Create a new taskGET /api/tasks- Get all tasks for the logged-in userPUT /api/tasks/:id- Update a taskDELETE /api/tasks/:id- Delete a task
PORT: Port number for the backend serverMONGO_URI: MongoDB connection stringJWT_SECRET: Secret key for JWTJWT_EXPIRATION: Expiration time for JWT tokens
REACT_APP_API_URL: URL of the backend API
Contributions are welcome! Please fork the repository and submit a pull request.
This project is licensed under the ISC License.