You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Full-stack task management app built with Laravel 12 & React 19
Overview
TodoList is a full-stack SPA that lets you manage tasks with categories, priorities, and due dates. The backend exposes a RESTful JSON API secured by Laravel Sanctum (cookie-based SPA auth — no tokens in localStorage). The frontend is a React 19 SPA with optimistic updates, global search, dark/light theme, and a responsive sidebar.
Screenshots
Login — Dark Mode
Register — Validation Feedback
Dashboard — Dark Mode
Dashboard — Light Mode
New Task Modal
New Category Modal
Upcoming Tasks — with Categories, Dates & Priority Labels
API also returns computed fields: priority_label, is_overdue, status.
Category
Field
Type
Description
id
integer
Primary key
user_id
integer
Owner
name
string
Unique per user (max 100)
color
string
Hex color (default #3B82F6)
icon
string · null
Icon identifier
API also returns computed field: pending_count.
Frontend Architecture
State management
Layer
Tool
Responsibility
Server state
TanStack React Query
Fetching, caching, background refetch
Auth state
React Context
Current user, login/logout
UI state
useState
Modals, filters, selected items
Query key conventions
queryKeys.todos.lists()// All todo list queriesqueryKeys.todos.list(params)// Specific list with paramsqueryKeys.todos.stats()// Dashboard statisticsqueryKeys.categories.list()// Category list
Authentication flow
Frontend calls GET /sanctum/csrf-cookie to obtain a CSRF token
User submits credentials → POST /api/login
Laravel creates a session and sets session + XSRF-TOKEN cookies
Axios reads XSRF-TOKEN automatically and sends it as X-XSRF-TOKEN on every mutating request
On page reload, GET /api/user restores auth state
POST /api/logout invalidates the session server-side
Available Scripts
Backend
php artisan serve # Start dev server (port 8000)
php artisan migrate # Run pending migrations
php artisan migrate:fresh # Drop all tables and re-migrate
php artisan db:seed # Seed demo data
php artisan tinker # Interactive REPL
Frontend
npm run dev # Start Vite dev server (port 5173)
npm run build # Production build
npm run preview # Preview production build locally
npm run lint # Run ESLint
License
MIT
About
Todo app engineered beyond basics — Laravel + React with focus on query optimization, algorithmic thinking, and scalable architecture patterns. Used as a testbed for performance improvement techniques.