Before trying out Sharepoint with MVC I’ve tried to think of what to expect:
Three points to think about when adding MVC to Sharepoint:
- Execution Model, routing and navigation
- Visual Controls
1. When installing MVC 2 Framework you are also installing bits that are installed by other installs. Don’t install it where VS2010 RC is installed, for instance (MVC 2 is included in that package). See ASP.NET-MVC-2-RC2-Release-Notes.doc.
MVC can be deployed to /bin/ folder instead of GAC. See 1) in http://weblogs.asp.net/scottgu/archive/2008/02/12/asp-net-mvc-framework-road-map-update.aspx.
2. The MVC execution model: http://msdn.microsoft.com/en-us/library/dd381612(VS.100).aspx uses global.asax for routing and .mvc extension for finding a handler.
How is it possible to mix that with the Sharepoint execution model?
3. Are you using only the visual controls of MVC or are you also using the routing? If you are only using the controls, then you might not have to consider that the routing interferes with Sharepoint.
MVC in Sharepoint suggestions
There is a couple of suggestions of how to incorporate MVC into Sharepoint:
I think what happens is:
A Sharepoint application page having a Sharepoint Masterpage redirects the rendering of the content to the MVC framework.
By using Sharepoint together with MVC I could see a good point in having Sharepoint beeing a presentation layer, using some WCF services below. Then when unittesting your app, you would just use MVC without Sharepoint and with Sharepoint, when you wanted the Sharepoint Masterpage.
More to be added at some time …