Understanding Dot Net Core Files and Folders Structure
When working on Dot Net Core as a Back End the project divides in the following main components and files (We are using Angular as a Front End in this project and Angular project structure already discussed in my previous article).
Connected Services
With Connected Services we can bring Azure workflow into Visual Studio for Mac. For example, you can add an Azure back end services like cloud data storage and authentication.
Dependencies
This folder contains all the internal, external, and third party references required to build and run our project.
Analyzers helps you maintain high quality code, it can raise errors/warnings/suggestions when you write less-than-ideal or plain low quality code.
Frameworks displays the framework used in the project. Here we can see that Microsoft Net Core is the framework installed.
Packages folder shows currently installed packages, it also shows NuGet package references added for this project, which we will install later as we need them. In the package folder we can see that we have Microsoft.AspNetCore.SpaService.Extension is installed it is for supporting single page application in our case it is an Angular.
Properties
The properties node contains launchSettings.json file, this file only used when we use our
application in local development machine or in debug mode. This file has nothing to do when we publish our application.
Here we can see in the file that ASP NET Core environment is Development.
And also we have two profiles IIS Express profile this profile will be used whenever we launched our application in debug mod, it is related to internet information server.
Other profile is related to our application FirstProject. This profile setting will be used whenever we start our application in console mode by running dotnet run command.
Controller
Which has been shipped with any MVC-based ASP.NET application since the preceding release of the MVC framework.
Controller handles all incoming requests from the Client ( Angular in our case) and send response back to the Client (Angular) mostly in JSON format.
Here we can see that WeatherForecastController is our controller name and it handles all the incoming requests destined for this controller. We will discuss more about Controller in upcoming articles.
Page
which contains a Razor Page file Error.cshtml to handle runtime and/or server errors. Whereas _ViewImports.cshtml file provides the mechanism to include directives globally.
Configuration
For the configuration of dot net core back end, such as modules, middleware compilation setting and project publishing we used three important files which are appsettings.json, Program.cs and Startup.cs.
appsetings.json: this file contains the setting information such as default connection string for connecting to the database.
Program.cs : dot net core mainly a console application and like every console application, Program.cs has a Main( ) method and this file is the starting point of our app.

Main( ) method starts the CreateHostBuilder() then this method configure logging, dependency injection and then further configure Kestral webserver also look at the configuration files such as appsettings.json and finally starts the Startup.cs file.
Startup.cs: This class is compulsory in dot net core application. Startup is a generic name we can give it any name to this file but we have to define it in webBuilder.UseStartup<>.
Startup class configures the Http request pipeline and utilize the Configure( ) method by adding the required middleware.
This class also has a ConfigureServices( ) method and in this method we can add and configure required service and dependency injection.
Here is a YouTube video Link of my Dot Net Core Project Structure tutorial (Urdu/Hindi language)
Written By
Syed Sohail Ahmed Quadri
YouTube Channel