The Model-View-ViewModel (MVVM) approach seem to be the front-runner pattern in WPF UI development. Almost every article I read implies that it is the best-practice. Usage of RelayCommand or DelegateCommand is also prominent in many articles and it seems like it is almost impossible to implement MVVM without using either of them (or any other variations). So why aren't they part of .NET 4?
I know that RelayCommand is really simple to implement and a lot of third party toolkits already have it but I'm just wondering why Microsoft would leave out something so basic and fundamental to the implementation of a so-called "best practice"?
Because Microsoft takes care of WPF, and not of MVVM.
If you want a full toolkit containing all components needed for a good MVVM application, I encourage you to take a look at Prism : A good tutorial here
The basic reason is that Microsoft is focusing on "mainstream" WPF functionalities (like enhancing Controls and Bindings). MVVM is, if I am right, "supervised" by the MVVM foundation.
As with most things it comes down to money. It may be a simple class, but including it in .NET requires a lot of work. A single class must be:
Each of these requires more work than you'd expect also (i.e. #2 would have first drafts, revisions, final approval, etc).
Found a relevant link here.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With