Commit e77b4898 authored by Almouhannad's avatar Almouhannad

(B) Add packages to API. Add comments to program.cs

parent fa70fd51
...@@ -2,10 +2,13 @@ var builder = WebApplication.CreateBuilder(args); ...@@ -2,10 +2,13 @@ var builder = WebApplication.CreateBuilder(args);
// Add services to the container. // Add services to the container.
#region Link controllers with presentation layer
var presentationAssembly = typeof(Presentation.AssemblyReference).Assembly;
builder.Services.AddControllers() builder.Services.AddControllers()
.AddApplicationPart(typeof(Presentation.AssemblyReference).Assembly); .AddApplicationPart(assembly);
#endregion
// Learn more about configuring Swagger/OpenAPI at https://aka.ms/aspnetcore/swashbuckle
builder.Services.AddEndpointsApiExplorer(); builder.Services.AddEndpointsApiExplorer();
builder.Services.AddSwaggerGen(); builder.Services.AddSwaggerGen();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment