Time goes fast and for the ASP.NET MVC team it even goes faster. I just figured out most of the features inside ASP.NET MVC 2 and version 3 is already showing up.
So what's new in ASP.NET MVC 3?
- Razor Syntax View Engine - Cleaner view syntax
- Dynamic View and ViewModel properties - passing data between controllers and views using dynamic rather than a dictionary
- "Add View" Dialog Box Supports Multiple View Engines - You two can be in this box.
- Service Location and Dependency Injection Support - Get your DI hooked into controller factories, dependency injection, action filters and View Pages.
- Global Filters - put filters on the all control methods
- New JsonValueProviderFactory Class - Model bind directly to JSON-encoded data
- Support for .NET Framework 4 Validation Attributes and IValidatableObject - Easier validation including validating one property based on another.
- New IClientValidatable Interface - Discovering at runtime if the client supports validation.
- Support for .NET Framework 4 Metadata Attributes - Support .NET 4 specific attributes like DisplayAttribute
- New IMetadataAware Interface - Write your own attributes to contribute to the ModelMetadata creation process.
- New Action Result Types - HttpNotFoundResult, HttpStatusCodeResult.
- Permanent Redirect - More easily return 301s for Actions, Routes or any URL.
Read more about it:
- Phill Haack’s blog: http://haacked.com/archive/2010/07/27/aspnetmvc3-preview1-released.aspx
- Scott Guthrie’s blog: http://weblogs.asp.net/scottgu/archive/2010/07/27/introducing-asp-net-mvc-3-preview-1.aspx
- Scott Hanselman’s blog: http://www.hanselman.com/blog/ASPNETMVC3Preview1ReleasedChannel9VideoAndHanselminutesPodcast224OhMy.aspx
- Brad Wilson’s blog:
- http://bradwilson.typepad.com/blog/2010/07/service-location-pt1-introduction.html
- http://bradwilson.typepad.com/blog/2010/07/service-location-pt2-controllers.html
- http://bradwilson.typepad.com/blog/2010/07/service-location-pt3-views.html
- http://bradwilson.typepad.com/blog/2010/07/service-location-pt4-filters.html