Skip to content

andhernand/todo-app

Repository files navigation

todo-app

This project is a simple Todo application that allows users to manage their tasks efficiently. The backend is built with a minimal API using .NET, while the frontend is developed with React and Vite.

Prerequisites

Getting Started

Clone the Repository

git clone https://github.com/andhernand/todo-app.git
cd todo-app

Setup Environment Variables

Create a .env file in the root directory of the project. This file contains the required environment variables for building and running the application and tests.

NOTE: The TODO_API_USER_NAME variable must remain as shown because it is hardcoded in the init.sql script.

TODO_API_SA_PASSWORD=YOURSTRONGSAPASSWORDHERE
TODO_API_USER_NAME="todoapi"
TODO_API_USER_PASSWORD=YOURSTRONGUSERPASSWORDHERE

Start MSSQL Server with Docker

Make sure Docker Desktop is running, then execute the following command to start the MSSQL server container:

docker-compose up -d

Note: Flyway by Redgate is used to manage and execute database migrations in this project.

Restore, Build, and Run

dotnet restore todo-app.sln
dotnet build todo-app.sln --no-restore
dotnet run --project src/todo-app.server/todo-app.server.csproj

Database Access with Dapper

This project uses Dapper for database access.

Input Validation with FluentValidation

FluentValidation is used to handle input validation.

Integration Testing

Integration tests utilize Testcontainers to create MSSQL databases for all integration tests. To run the tests, use the following command:

dotnet test todo-app.sln

Contributing

Contributions are welcome! Please fork this repository and submit a pull request with your changes.

License

This project is licensed under the MIT License. See the LICENSE file for more details.

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 2

  •  
  •