开发者

Extensible ASP.NET MVC Web Application

开发者 https://www.devze.com 2023-02-16 21:17 出处:网络
I need to write a web application with ASP.NET MVC 3 that should be completely modular and extensi开发者_高级运维ble. A module/extension would be, for example - a forum, a blog or a content module.

I need to write a web application with ASP.NET MVC 3 that should be completely modular and extensi开发者_高级运维ble. A module/extension would be, for example - a forum, a blog or a content module.

I thought about using multi-project MVC areas for this purpose, so I have an Extensions/ directory with the .dll-s of the extensions, and on Application_Start (or maybe on an earlier step), it loads all the extensions in that directory to current AppDomain.

Is there any better way to do this? I mean, maybe not using MVC areas at all? Maybe using MEF? I have a very little experience with MEF, and I'd like to learn, but I just don't know if that fits my project. Maybe using MVC Areas + MEF?

As you can see, I'm pretty confused and would like to have a clarification :)

Thanks.


I'm looking into something similar. I've yet to start but so far I've read this which seems promising.

It appears that MVC3 has specific interfaces for IoC, so you want to spend most of your time looking at MVC3+MEF examples. Some of the older examples are less relevant.

If you want your views to be easily extensible then this seems like a good idea.


I've done quite a few topics on using MEF with ASP.NET MVC. It works quite well, but it is not as polished as say portable areas in the MVCContrib project.

MVC3 + MEF: http://www.fidelitydesign.net/?p=259

MVC2 + MEF: http://www.fidelitydesign.net/?p=159

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号