MVVM pain points

MVVM was touted as THE PATTERN to go for when Microsoft introduced WPF. It got more attention when Silverlight which was a thin down version of WPF released later.

Now both the technologies are going back to the shelf does the pattern MVVM still sounds good ?. MVVM do provide a strong pattern for Data Binding, Design and Testing it also has bunch of pain points which are hightlighted below :

  • Microsoft hasn’t given clear directions on this pattern yet, and the various non­Microsoft resources available on the topic can send mixed messages, leaving developers and architects confused.
  • Need for boilerplate code, complicated techniques and/or frameworks. Things like property changed notifications and commands require lots of boilerplate code and potentially brittle designs that require using “magic strings”.  Even though there are open source frameworks available one may not want to or may not be allowed to use open source frameworks.
  • Only supported in WPF and Silverlight: This pattern doesn’t transfer well to technologies such as ASP.NET or WinForms easily.