Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Should I migrate to ASP.NET MVC?

Tags:

asp.net-mvc

I just listened to the StackOverflow team's 17th podcast, and they talked so highly of ASP.NET MVC that I decided to check it out.

But first, I want to be sure it's worth it. I already created a base web application (for other developers to build on) for a project that's starting in a few days and wanted to know, based on your experience, if I should take the time to learn the basics of MVC and re-create the base web application with this model.

Are there really big pros that'd make it worthwhile?

EDIT: It's not an existing project, it's a project about to start, so if I'm going to do it it should be now...


I just found this

It does not, however, use the existing post-back model for interactions back to the server. Instead, you'll route all end-user interactions to a Controller class instead - which helps ensure clean separation of concerns and testability (it also means no viewstate or page lifecycle with MVC based views).

How would that work? No viewstate? No events?

like image 399
juan Avatar asked Aug 27 '08 13:08

juan


People also ask

Is ASP.NET MVC still relevant?

ASP.NET MVC is no longer in active development. The last version update was in November 2018. Despite this, a lot of projects are using ASP.NET MVC for web solution development. As to JetBrains' research, 42% of software developers were using the framework in 2020.

Is ASP.NET MVC worth learning?

Definitely yes. In today's world of Cloud computing, micro-services, and containers, you need a web development framework that is lightweight, cross-platform and easy to deploy.

What is the use of migration in MVC?

The Migrations feature enables you to change the data model and deploy your changes to production by updating the database schema without having to drop and re-create the database.

Why ASP.NET MVC is better?

The main advantages of ASP.net MVC are: Enables the full control over the rendered HTML. Provides clean separation of concerns(SoC). Enables Test Driven Development (TDD).


1 Answers

If you are quite happy with WebForms today, then maybe ASP.NET MVC isn't for you.

I have been frustrated with WebForms for a really long time. I'm definitely not alone here. The smart-client, stateful abstraction over the web breaks down severely in complex scenarios. I happen to love HTML, Javascript, and CSS. WebForms tries to hide that from me. It also has some really complex solutions to problems that are really not that complex. Webforms is also inherently difficult to test, and while you can use MVP, it's not a great solution for a web environment...(compared to MVC).

MVC will appeal to you if... - you want more control over your HTML - want a seamless ajax experience like every other platform has - want testability through-and-through - want meaningful URLs - HATE dealing with postback & viewstate issues

And as for the framework being Preview 5, it is quite stable, the design is mostly there, and upgrading is not difficult. I started an app on Preview 1 and have upgraded within a few hours of the newest preview being available.

like image 52
Ben Scheirman Avatar answered Sep 19 '22 17:09

Ben Scheirman