I understand that the minimum Nuget packages that I need for an ASP.NET MVC 4 Project are:
However I am interested to know, what would the following packages add to the project?
i.e. What do these two packages do? The description for each of these nuget projects is the same description as Razor 2 package, which isn't too helpful.
Put simply, a NuGet package is a single ZIP file with the . nupkg extension that contains compiled code (DLLs), other files related to that code, and a descriptive manifest that includes information like the package's version number.
NET and Visual Studio. NuGet can be used to find and install packages, that is, software pieces and assemblies and things that you want to use in your project. NuGet is not a tool that is specific to ASP.NET MVC projects.
After doing some experimenting with MVC 4 Projects with and without the following packages
I have come to the conclusion that the Nuget Package description of
This package contains the runtime assemblies for ASP.NET Web Pages. ASP.NET Web Pages and the new Razor syntax provide a fast, terse, clean and lightweight way to combine server code with HTML to create dynamic web content.
is very misleading.
The Microsoft ASP.NET Web Pages 2 Data actually just contains the WebMatrix.Data.dll. This the only assembly that is added to your project when adding this package. Looking at the MSDN reference for this assembly
The WebMatrix.Data namespace contains classes that simplify database interaction in ASP.NET Web Pages. This namespace includes classes that help you to open, query, and send commands to a database, and to work with database rows that are returned by SQL queries.
And for the Microsoft ASP.NET Web Pages 2 Web Data, this package only adds the WebMatrix.DataWeb.dll (dependent on WebMatrix.Data.dll). The MSDN reference for this assembly is
The WebMatrix.WebData namespace contains classes that simplify membership and security in ASP.NET Web Pages. This namespace includes classes that help you create and delete user accounts, define roles, and manage account passwords.
So if not using WebMatrix Data to access databases and not using the simple membership provider, these packages are unnecessary.
If you are using the Simple Membership provider, or extending the Extended Membership Provider, then these packages are necessary.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With