Another V-M-VM question for you (easier than my previous one…)
Let’s suppose to have a Window divided in 3 areas each one independent from each other, how do you provide ViewModels to those Areas?
Option 1: A common container esposing 3 properties ContextA,ContextB etc… associated to Windows’s DataContext and each area container bound using {Binding Container.ContextA}
Option 2: Each different ViewModel is explicitly bound to area’s datacontext, e.g:
Grid1.DataContext=new ContextA();
Grid2.DataContext=new ContextB();
Etc…
Option 3: Others?
I know that final result is the same, just curious about your way of working and pros/cons of each solution.
Corrado