Are there any frameworks for using MEF, for example for WPF application there are number of frameworks to save time, but what is there for MEF? are we to start every MEF application from scratch or is there some existing framework that utilises MEF and uses good practices and patters for software engineering with MEF.

I have been googling around for 2 days, and all I have found was MEF 2.0 for .Net Core, but nothing on established patterns and practices using MEF, after so many years that MEF came out one would expect people would have had enough of starting each project from scratch and have started using frameworks for MEF.

8 years ago this question was asked : How are you using the Managed Extensibility Framework?

I have been trying to find out material and information on best patterns and practices MEF usage, as it was mentioned in that question since but it seems 2010-2011 was the last time anyone looked at best practices with MEF :




Tried searching for books, all the books, there seems to be nothing published in past 5 years on MEF, or no common practices/patterns/frameworks.

If MEF was as important and promising, why there are no dedicated books for it like WPF, WCF etc. ?


MEF is essentially an IoC container.

The difference between MEF and other IoC containers is that MEF deals with modules that are not known until runtime, unlike an ordinary IoC container that deals primarily with dependencies that are already known at compile time.

It thus lends itself to plugin architectures and dependency discovery mechanisms.

With a little imagination, you could write your own discovery and instantiation engine that works essentially like MEF without too much trouble, using Reflection, Activator.CreateInstance, and a handful of mapping attributes.

So, there really isn't enough material to fill a book here. The MSDN documentation on MEF should suffice.

  • 1
    @Arjang: Yeah, I get it. But people have been lawyering the term "IoC container" for years. Note the word essentially in my first paragraph. – Robert Harvey Jan 17 '19 at 3:17
  • yes, thank you, please note I should have said "btw just fyi" and not "fyi", it is a real minor unessential point that I should have left alone. :) – Arjang Jan 17 '19 at 3:30

Not the answer you're looking for? Browse other questions tagged or ask your own question.