I am not starting an argumentative discussion here and this post is not about career development, but from the commercial point of view:
If a company was using ASP.Net MVC as a main methodology to build their web sites and application.
However, ASP.Net MVC takes more time to show a functional application than ASP.Net Web Forms, for example, building domain models would take some time which obviously can’t be represented on a UI at that current stage.
My question is, if a client wants to see a functional demo application (just a proof of concept) so he knows that the company he is dealing with is professional and capable of doing that. Would it be better to do that demo in ASP.Net Web Forms only to show the client, and then work on the real application using ASP.Net MVC? If not, what are the (quick) alternatives?, I mean, if we tell the client to wait till we have a working demo (by ASP.Net MVC) we may lose the client and the whole project opportunity.
WebForms being faster than MVC is a myth:
btnSubmit_OnSubmitis almost identical to theHttpPostcontroller actions. Except with MVC you don’t have to write left to writeobject.FirstName = txtFirstName.Textwhen you understand how UpdateModel works.Fast MVC comes from understanding how to get the most bang from your buck using
EditorFor,DisplayFortemplates. You’ll need to know and understand how to customize your Object.ascx file. With this technique under your belt you won’t have to create forms by hand anymore. 2 projects ago we had a site with 100% autogenerated forms. Change a class, change a form. Done!Another helpful MVC tool is the DataAnnotations attributes. Validation made easy. Customizing these is really easy too. Just create your own
ModelMetaDataProviderand starting expanding the validations your application can handle.The only part of MVC that is slower is displaying a grid. MVC 3 already has a useful grid tool and MVCContrib has had a grid tool out for a year now. I ended up rolling my own, its very simple actually, loop through properties, write
<td />‘s. < 200 lines of code. This isn’t really a benefit to WebForms either. To use WebForms grid components means giving up a lot of quality using ObjectDataSources and the like.To summarize fast MVC comes from these different techniques:
If you are more advanced and know ORMS like EntityFramework and how to use Automapper your probably going to be even faster.