English 中文(简体)
.NET Core - Modularity
  • 时间:2024-11-03

.NET Core - Modularity


Previous Page Next Page  

It is another consideration of .NET Core to build and implement apppcation that is modular. Instead of instalpng the entire .NET Framework, your apppcation can now just install what is required. Let us go to the visual studio and see the modularity.

Here is our simple .NET Core apppcation, in Solution Explorer. Let us expand References and you will see reference to .NETCoreApp

.Net Core App

Inside .NETCoreApp, you will see package reference to NuGet; let us expand it.

NuGet

You will see the whole series of NuGet Package references. If you have worked in .NET Framework, then many of these namespaces will look famipar, because you are used to it by using in .NET Framework.

.NET Framework is sppt into many different pieces and re-implemented with CoreFx; these pieces are further distributed as inspanidual packages.

Framework

    Now if you expand the NETStandard.Library, you will see addition references. You will even notice System.Console which we are using in this apppcation.

    Now you don’t have to bring in everything inside the .NET Framework, but just bring in what you need for your apppcation.

    There are some other benefits as well; for example, these modules can be updated inspanidually if desired.

Modularity leads to performance benefits and your apppcation can run faster, especially ASP.NET Core apppcation.

Advertisements