ASP.NET MVC is heavily based on conventions, a “configuration convention,” as they say. Thus, this means that what is given is the name and where they are created in the project structure.
As a newbie to ASP.NET MVC, I appreciate the strength and simplicity of this approach, but it seems to me a little confusing to keep track of which conventions are in the game. For example, when using the controller method UpdateModel, which uses HTML form fields that have the same names as the model class properties. This is an obvious thing, and most of the time this is probably what most people will do instinctively, but I see that it will be very confusing if someone renames something in one place and forgot to rename it to another. The connection is somewhat fragile.
So, I thought it would be useful to have a list of all ASP.NET MVC conventions here in one place, as brief statements on best practice. such things as:
"HTML form fields must have the same name as" Model Properties. "
Does anyone have anything like this? Will you help me create a list here?
source
share