Skip to main content

Posts

Showing posts from May, 2010

Why You Should Consider MVC 2 for Your Next ASP.NET Web Site

You have many choices when you set out to design a new web site. Some people might say that you have too many choices. For the purposes of this article, I'm going to assume that you've already decided that you're going to use ASP.NET in one form or another, so won't presume to debate the merits of Windows versus Linux hosting. Instead I'm going to focus on a real project where we chose MVC Release 2 for a redesign of an existing ASP.NET WebForms site.

There are four main reasons that helped us decide on using ASP.NET MVC for our project: Testability Clean, SEO-Friendly URLsFull Control of the HTML generatedWe got to delete a lot of code!Testability By default, MVC projects encourage the practice of test-driven development. Each controller can be paired with a controller test class that exercises the controller's functionality without regard to the view that will ultimately render in the UI. Testing each controller's methods in this way ensures a clean se…