I used MEFedMVVM to create a lightweight code sample browser application to demonstrate a simple use of the MVVM pattern in Silverlight that employs MEF to couple such common services as a singleton model and view model messenger (mediator).
The download archive is available here:
The code sample browser is divided into five projects and uses MEF to import and export implementations between the different modules. MEFedMVVM is used to connect the views with their respective view-models. The five projects and their purposes are as follows:
The main Silverlight application. This contains the xaml files that implement the views, styles, and converters necessary to present the application.
This project contains the view-models that provide the functional interface to the application. The two main view models provide interfaces for the code sample list (navigation) and code sample detail layouts.
The model and core system code. The runtime implementation of ICodeBrowserModel is declared and exported as a singleton.
POCOs (Plain Old CLR Objects) are declared here. They form the currency used to communicate domain values between modules.
A simple ASP.NET project used to host the Silverlight application during development.
Disclaimer: This code is provided as is, without warranty, and without guarantee of fitness for any purpose. Use at your own risk.