0

Building an MVC web application. Will be a single page app highly driven by javascript (require.js, pager.js, jquery, knockout, etc).

This application would have its own built-in pages, controllers, etc - and would need to be able to accept external plug-and-play functionality as well.

Ideally, I could just drop a .dll from another MVC web app into the main app and it would inherit not only the dropped in app's controllers, but would also bring in its web files (.htm, *.ts, *.js, *.css, etc).

Imagine having a home page with tiles for each installed dll. Referencing a new dll would add the app's tile to the home page - which is an entry point into the app.

Each plug-and-play app would need to adhere to our routing design (for MVC controllers and PagerJS).

Lastly, each app would need to be able to share user login data.


I know my questions are a bit broad, but I just wanted to get some ideas and see where it takes me.

tereško
  • 58,060
  • 25
  • 98
  • 150
franzcatch
  • 169
  • 2
  • 15
  • http://msdn.microsoft.com/en-us/library/dd460648(v=vs.110).aspx – Robert Harvey Nov 25 '13 at 20:31
  • I've seen this question a few times and now of course can't find them, but as far as I recall the consensus was to create a NuGet package of your MVC "base" sites and adding those packages to other sites. See for example [All you need to create a Nuget package for ASP.NET MVC](http://www.codeproject.com/Articles/593605/All-you-need-to-create-a-Nuget-package-for-ASP-NET) on CodeProject. – CodeCaster Nov 25 '13 at 20:37

1 Answers1

0

MvcContrib has introduced Portable Area that is a set of reusable multi-page functionality can be dropped into an application to provide rich functionality without having to custom build functionality that is literally the same in every application.

This could be considered a plug-in or add-in type of functionality. The portable portion of this approach is that the area can be distributed as a single assembly rather than an assembly and a host of other files, like views or other html assets that need to be managed and maintained over time.

By making a portable area totally self contained in a single assembly, this should allow for easier reuse and upgrades to the area. The challenge for doing something like this has been how do you allow enough control over the User Interface by the application yet still allow the actual views to be packaged with the logic.

The description above is a part of a popular project in CodePlex which could help you to understand/use the technology behind the concept of Plug-able MVC application.

ASP.Net MVC Portable Areas via MvcContrib is a post by Eric Hexter that describes Portable Area in detail.

Abbas Amiri
  • 3,074
  • 1
  • 23
  • 23