title: Order of setting DataContext in code behind
body: <p>Which one is the right way to set DataContext in code behind:</p>
  
  <pre><code>public ViewConstructor()
  {
      InitializeComponent();
      DataContext = new MyViewModel();
  }
  </code></pre>
  
  <p>or</p>
  
  <pre><code>public ViewConstructor()
  {
      DataContext = new MyViewModel();
      InitializeComponent();
  }
  </code></pre>
  
  <p>?</p>