An open API service indexing awesome lists of open source software.

https://github.com/stpfeffer/todo-list

A simple To Do application written with Typescript and Next.js
https://github.com/stpfeffer/todo-list

mongodb nextjs react typescript

Last synced: 10 months ago
JSON representation

A simple To Do application written with Typescript and Next.js

Awesome Lists containing this project

README

          

# ToDo Application

A simple yet powerful ToDo application that helps you manage your tasks efficiently. Whether you need to keep track of personal chores, work tasks, or anything in between, this application is designed to keep you organized.

## Table of Contents

- [Features](#features)
- [Getting Started](#getting-started)
- [Prerequisites](#prerequisites)
- [Installation](#installation)
- [Docker Setup](#docker-setup)
- [Usage](#usage)
- [Running the Application](#running-the-application)
- [Technologies Used](#technologies-used)
- [Project Structure](#project-structure)
- [Contributing](#contributing)
- [License](#license)
- [Contact](#contact)

## Features

- **Task Management**: Create, update, delete, and view tasks.
- **Due Dates**: Assign due dates to tasks and get reminders.
- **Categories**: Organize tasks by categories (e.g., Work, Personal).
- **Priorities**: Set task priorities (Low, Medium, High).
- **Search & Filter**: Easily search and filter tasks.
- **Responsive Design**: Fully responsive UI for mobile and desktop.
- **Authentication**: Secure user login and registration.
- **Notifications**: Get email and push notifications for due tasks.
- **Dark Mode**: Toggle between light and dark themes.

## Getting Started

### Prerequisites

To run this application, you will need the following installed on your machine:

- [Node.js](https://nodejs.org/) (v14.x or later)
- [npm](https://www.npmjs.com/) (v6.x or later)
- [MongoDB](https://www.mongodb.com/) (for local database setup)

### Installation

1. **Clone the repository:**

```bash
git clone https://github.com/your-username/todo-app.git
cd todo-app
```

2. **Install dependencies:**

```bash
npm install
```

3. **Set up environment variables:**

Create a `.env.local` file in the root of the project and add the following:

```plaintext
NODE_ENV=development
PORT=3000
MONGODB_URI=mongodb://localhost:27017/todoapp
JWT_SECRET=your_jwt_secret
```

4. **Set up the database:**

Make sure MongoDB is running locally, or update the `MONGODB_URI` in the `.env.local` file to point to your MongoDB instance.

### Running the Application

To start the application in development mode:

```bash
npm run dev
```

The application will be available at `http://localhost:3000`.

## Docker Setup

To run the application using Docker Compose:

Build and start the Docker containers:

```bash
docker-compose up --build
```

Access the application:

The application will be available at http://localhost:3000.

The `docker-compose.yml` file sets up the following services:

Web: The Next.js application running on Node.js.
MongoDB: The MongoDB database.

## Technologies Used

- **Frontend**: React.js, Next.js, TailwindCSS
- **Backend**: Node.js, Axios
- **Database**: MongoDB
- **Language**: TypeScript
- **Authentication**: JWT (JSON Web Tokens)

## Project Structure

```plaintext
├── src
│ ├── actions # Axios calls for interacting with the backend API
│ ├── app # Reusable React components
│ ├── components # Reusable React components
│ ├── config # Next.js pages and API routes
│ ├── db # Database setup and connection logic
│ │ └── models # MongoDB models
│ ├── services # Business logic and services
│ ├── styles # TailwindCSS styles and global CSS
│ ├── types # TypeScript types and interfaces
│ └── utils # Utility functions
├── public # Static files (images, icons, etc.)
├── tests # Test files
├── next.config.js # Next.js configuration
├── tailwind.config.js # TailwindCSS configuration
├── tsconfig.json # TypeScript configuration
├── package.json
└── README.md
```

## Contributing

We welcome contributions to the ToDo application! To contribute:

1. Fork the repository.
2. Create a new branch (`git checkout -b feature-branch`).
3. Make your changes and commit them (`git commit -am 'Add new feature'`).
4. Push the branch (`git push origin feature-branch`).
5. Open a pull request.

Please refer to the [CONTRIBUTING.md](docs/CONTRIBUTING.md) for more details.

## License

This project is licensed under the MIT License. See the [LICENSE](LICENSE) file for details.