This project provides an improvement for the .net react template with authentication. Most javascript files are replaced with typescript files. The sql database from the original template is replaced with a postgres database. I added a docker-compose to easily configure the database. This project also includes tailwind but currently it's not used. Adding tailwind styles to html elements should work instantly. Finally I also changed the project structure, which is better suited for large projects.
-
Running the code:
- Go inside AspNetCoreReactWebApp.Web/ClientApp
- run command:
npm install
(only once)
-
Docker:
- Change the docker-compose to your needs!
- afterwards run command:
docker compose up
-
Adding migrations:
- Go into AspNetCoreReactWebApp.Data
- run command:
dotnet ef migrations add Initial -s ../AspNetCoreReactWebApp.Web/
-
Renaming project (optional and be careful with this): If you want to rename the project you must rename following things: root folder, sln file, project folders, projects inside the sln file, csproj file name and the project references it includes (do this in each project folder), usings and namespaces. When finished remove all bin and obj folder if they exist already.
- Go inside AspNetCoreReactWebApp.Web
- run command:
dotnet run