A mini Chinese novels reader which was built based on traditional Three-layer architecture with ASP.NET Core and Dependency Injection for loose coupling.
- For front-end side:
- Using React for smooth UI and also some related libraries. i.e: Framer-motion for animation and Tailwindcss for all styling stuffs in the project.
- Also using axios to facilitate the API callings.
- For back-end side:
- Using ASP.NET Core for exposing API to clients.
- Based on Three-layer architecture with three main layers: Data (DAL), Services (BLL) and WebApp (UI).
- Using SQL Server for persistence.
- Cloud Services:
- AWS EC2: for deployment.
- AWS RDS: A storage solution in Production environment.
- AWS SES: Delivering recovery email to the users.
-
Clone the project.
-
Navigate to the src/miranaSolution.API folder and configure change the connection string in appsetings.json:
"ConnectionStrings": { "Database": "Server=localhost;Database=MiranaSolution;Trusted_Connection=True;" }
Also change the other settings if needed.
-
To create the migration and update the database, turn back to the root folder and run the commands below:
dotnet ef migrations add Initialize -s ./src/miranaSolution.API/ -p ./src/miranaSolution.Data/ dotnet ef database update -s ./src/miranaSolution.API/ -p ./src/miranaSolution.Data/
-
Finally, run the following command to start the API:
dotnet publish -c Release dotnet ./bin/Release/net6.0/miranaSolution.API.dll
- Navigate to the src/frontend/miranaSolution.WebApp folder, then create the
.env
file with those contents:ReplaceVITE_BASE_ADDRESS=<API-Address>
<API-Address>
with the API Address when running API above - Build the WebApp project:
npm run build
Just simply go to the root/tests/miranaSolution.Services.Tests and run the command:
dotnet test