A simple, yet well-structured todo list application built with Node.js/Express backend and vanilla JavaScript frontend. Features in-memory storage, Docker support, and comprehensive testing.
index.html
- Main frontend interfacestyle.css
- Application stylingapp.js
- Frontend JavaScript logicserver.js
- Express backend server
package.json
- Project dependencies and scripts.env
- Environment variables configuration.gitignore
- Git ignore patterns.dockerignore
- Docker ignore patternsDockerfile
- Docker container configuration
- APP.md - Detailed application architecture and design patterns
- DOCKER.md - Docker setup and best practices
- TESTING.md - Testing strategy and examples
server.test.js
- API endpoint tests using Jest and Supertest
- Install dependencies:
npm install
- Start the application:
npm start
- Run tests:
npm test
Build and run with Docker:
docker build -t mytodolist .
docker run -p 3000:3000 mytodolist
-
Frontend
- Clean, responsive UI
- Real-time updates
- Error handling
-
Backend
- RESTful API
- Express server
- In-memory storage
-
Development
- Hot reloading support
- Environment configuration
- Comprehensive testing
-
Application Architecture (APP.md)
- Component hierarchy
- Design patterns
- Code organization
-
Docker Setup (DOCKER.md)
- Container architecture
- Best practices
- Development workflow
-
Testing Strategy (TESTING.md)
- Test architecture
- Example tests
- Best practices
GET /api/todos
- Retrieve all todosPOST /api/todos
- Create a new todoPUT /api/todos/:id
- Toggle todo completionDELETE /api/todos/:id
- Remove a todo
npm start
- Start the servernpm test
- Run testsnpm run dev
- Start with hot reloading
- Detailed design patterns in APP.md
- Docker configuration in DOCKER.md
- Testing examples in TESTING.md