title: How to invoke Javascript in .NET in WPF & WinRT?
body: <p>Here is a use case.  I need to:</p>
  
  <ul>
  <li>Invoke JavaScript from .NET (C#) code</li>
  <li>JavaScript won't be compile, it comes from a dynamic source</li>
  <li>I need to pass .NET objects to that javascript code, preferable a dynamic object</li>
  <li>I also need to receive objects back from this javascript code</li>
  <li>I need this code to run in WPF (Windows 7) &amp; Windows Store (WinRT)</li>
  </ul>
  
  <p>So far I've only seen activation of Windows Script Engines (i.e. <a href="http://msdn.microsoft.com/en-us/library/xawadt95%28VS.85%29.aspx" rel="nofollow">IActiveScript</a>) or using open source project.</p>
  
  <p>I would prefer to stay clear of Open Source project and would prefer to use IE JavaScript engine (Chakra).  Windows Script Engine doesn't seems to work on WinRT.  I can live with hosting a browser in my app as it is a UI app.</p>
  
  <p>Code doesn't need to be identical in WPF &amp; WinRT (I can write something to wrap the two implementation behind an common interface).</p>
  
  <p>How can I do that?</p>