Separating app parts in your meetings when using Prism

The MVVM approach encourages (or just makes it possible) to break a WPF or Silverlight application into Model, ViewModel, and View projects, so all three can exist in their own assemblies.

Using Prism (and, in my case, MEF as a container for dependency injection), on the other hand, you can build a modular application that is divided into a set of functional blocks (named modules), and each block, in this case, is a separate assembly .
Is it right that in this case we can only separate the model in our own assembly, but the View and ViewModel should sit in the same assembly, representing one functional module?

+2
source share
2 answers

First of all, the module is not equal to the assembly. You can distribute parts of a module between several assemblies (including Models, Views, and ViewModels). Although, as a rule, you place the classes associated with the module in a single DLL or XAP file (in the case of Silverlight, if your module is a separate Silverlight application).

, , , Prism , . MVVM , -. , MVVM, , .

+4

, (, ) .

. , .

, , MVVM. -, . -, , .. . , , , , .

+3

Source: https://habr.com/ru/post/1795956/


All Articles