I suggest you ...

Provide native support in the IDE for MVVM

Something like where VS has a "code mode" for code behind or MVVM or other pattern.

If MVVM is selected then the IDE helps us fall into the pit of MVVM success.

Even better would be a coding mode provider model, so other patterns could be plugged in over time

1,317 votes
Sign in
Sign in with: facebook google
Signed in as (Sign out)
You have left! (?) (thinking…)
anonymous shared this idea  ·   ·  Flag idea as inappropriate…  ·  Admin →


Sign in
Sign in with: facebook google
Signed in as (Sign out)
  • Lars Pedersen commented  ·   ·  Flag as inappropriate

    Binding the View to the ViewModel is currently too hard for the developer.

    There should be a user-friendly way to bind the View elements to the VM. Something like a tree browser that allows you to pick the property in the VM or View and assign a converter which then generates the markup for you.

    Also, there needs to be window that shows binding errors in a user friendly way, with options to fix them (like what IntelliSense does for library references).

  • Ro We commented  ·   ·  Flag as inappropriate

    Vs should have mvvm for all wpf, uwp, xamarin.
    Mvvm including all sub-Patterns.
    So, also small apps would have a unified design.

  • liero commented  ·   ·  Flag as inappropriate

    Do you think that code-snippets and custom item templates distributed trough nuget would solve your case? They would be active only in projects that references the nuget packages.

    For example, when you install Prism.MVVM you would get item templates like Page with ViewModel and code snippets like propnotify, etc, etc.

    Additionally, you may introduce snippets and templates highly specific for your project, since basic page or user control will probably look differently for each project.

    If you want to navigate from View to ViewModel, just press F12 (go to definition), in the d:DataContext declaration.

    Vote for the idea here if you like it: https://visualstudio.uservoice.com/forums/121579-visual-studio-ide/suggestions/17776780-code-snippets-and-item-templates-distributable-tro

  • badreddine commented  ·   ·  Flag as inappropriate

    yes i think so
    "XAML Power tools" seems more interesting that automatic code behind IDE
    at least integrate this tool with the IDE

  • Daver commented  ·   ·  Flag as inappropriate

    Yes, the basic Models and Views should be automatically code generated by VIsual Studio. It's unnecessary grunt work and if it's automatically there, people will lean towards using it. Perhaps Visual Studio should also have templates for patterns as well.

  • Greg Duncan commented  ·   ·  Flag as inappropriate

    Allow us to pick a pattern of choice, and then have the IDE help us fall into the pit of success by supporting that pattern. So something like replacing the current code behind model with a plug-in'able/replaceable model, with MVVM being just one such model. If "code behind" is bad, then let the IDE help us by implementing a given pattern and not force use to jump through hoops to implement them. WPF/Silverlight/xaml's awesome databinding is the first step, now let's improve that by making the IDE "understand" a pattern of choice, like MVVM

Feedback and Knowledge Base