README.md
A full-stack task management web application with user authentication, task CRUD operations, and task filtering capabilities.
Built with Golang using Gin framework for the backend API, and React for the frontend UI.
- Project Overview
- Project Demo
- Features
- Technology Stack
- Backend Architecture
- Frontend Architecture
- Setup and Installation
- API Endpoints
- Usage
- Future Enhancements
- Testing
- Contact
This Task Manager App enables users to register and authenticate securely using JWT tokens. Authenticated users can create, view, update, and delete their personal tasks. Tasks support fields such as title, description, status, and due date. The frontend provides an intuitive React interface with live filtering of tasks by status and real-time updates.
This project demonstrates ability to build scalable, secure full-stack applications with clean code architecture, modular design, and modern best practices.
Watch this 7-minute video where I walk through the features, architecture, and usage of the Task Manager App.
- User registration & secure login with password hashing and JWT authentication.
- User-specific task CRUD functionality:
- Create tasks with title, description, status, and optional due date.
- View a list of all your tasks.
- Edit task details.
- Delete tasks.
- Filtering tasks dynamically by status.
- Responsive and accessible React frontend.
- Centralized API client managing JWT tokens for authenticated calls.
- Persistent login via token stored in local storage.
- Loading and error state management.
- Well-structured and documented codebase.
- Comprehensive unit and integration tests.
-
Backend:
- Go (Golang)
- Gin Web Framework
- GORM ORM
- SQLite (development database)
- JSON Web Tokens (JWT) for authentication
- bcrypt for password hashing
-
Frontend:
- React
- Axios for API calls
- Context API for auth state management
- HTML5, CSS3
-
Development Tools:
- Postman (API testing)
- Go testing package + httptest
- Create React App
- Models:
User: Stores user info with hashed password.Task: Stores tasks linked to users (UserIDforeign key).
- Authentication:
- Secure password storage with bcrypt.
- JWT tokens issued at login, validated via middleware on protected routes.
- Routing:
- Public endpoints:
/register,/login. - Protected endpoints (with JWT middleware):
/tasksCRUD and/health.
- Public endpoints:
- Services:
- Business logic layer interacts with database via GORM.
- User-specific task filtering is enforced in services.
- Middleware:
- JWT verification extracts username from token and sets context for handlers.
- Database:
- SQLite for ease of development, migrations handled by GORM.
- Authentication Context:
- Stores authenticated user and JWT token.
- Provides
loginandlogoutfunctions. - Token stored and retrieved from
localStorage.
- Components:
LoginandRegister: Manage user authentication flows.TaskForm: Handles task creation and editing with validation.TaskList: Displays filtered list of tasks.TaskItem: Represents single task with edit/delete controls.
- API Client:
- Axios instance configured with interceptor to attach JWT token to all API requests.
- State Management:
- React
useStateanduseEffectfor fetching & managing tasks. - Error and loading states are handled gracefully.
- React
- Filtering:
- UI dropdown to filter tasks dynamically by status with immediate feedback.
- Install Go (version 1.18+ recommended) from golang.org.
- Clone this repository.
- Navigate to the backend directory.
- Run:
go mod tidy go run cmd/main.go
- Server listens on port
8080.
- Node.js (version 14+) and npm/yarn installed.
- Navigate to frontend directory.
- Run:
npm install npm start
- The app will open on
http://localhost:3000and proxy API requests to backend.
| Method | Endpoint | Description | Auth Required |
|---|---|---|---|
| POST | /register |
Register a new user | No |
| POST | /login |
Log in and receive JWT token | No |
| GET | /tasks |
Get all tasks for authenticated user | Yes |
| POST | /tasks |
Create a new task | Yes |
| PUT | /tasks/:id |
Update a task by ID | Yes |
| DELETE | /tasks/:id |
Delete a task by ID | Yes |
| GET | /health |
Health check endpoint | No |
- Register a new user.
- Log in with credentials.
- Use the task management UI to add, edit, delete, and filter your tasks.
- Tasks are saved per user and secured with JWT authentication.
- Logout to clear the session.
- Add filtering by due date and search.
- Add task priorities and categories.
- Implement real-time updates with WebSockets.
- Support file attachments to tasks.
- Improve UI/UX with animations and accessibility improvements.
- Add role-based access control and admin features.
- Implement mobile-friendly responsive design.
-
Backend tests cover user registration, login, authorization middleware, and CRUD operations.
-
To run backend tests:
go test ./internal/handlers -v -
Frontend testing can be added with Jest and React Testing Library.
For questions or feedback, please contact:
Your Name
Email: shagunsharmadev@gmail.com
GitHub: Shagun Sharma
Thank you for reviewing my Task Manager Application! I look forward to your feedback.
