title: ModelBinder deserialize arbitrary json
body: <p>I'm having trouble getting the default model binder to work as expected for the following data structure:</p>
  
  <p>json:</p>
  
  <pre><code>{
      template: "path/to/template",
      slides: [{
          index: 0,
          context: {
              foo: "bar"
          }
      }, {
          index: 1,
          context: {
              foo: 'bar!',
              table: [
                  ['Price', 'Revenue', 'Profit'],
                  [$5', 100, 20],
                  ['$10', 320, 4],
                  ['$7', 50, 2]
              ]
          }
  
      }]
  }
  </code></pre>
  
  <p><code>IPresentationData</code> model:</p>
  
  <pre><code>public interface IPresentationData
  {
      public string Template { get; set; }
  
      public ICollection&lt;SlideData&gt; Slides { get; set; }
  }
  </code></pre>
  
  <p><code>ISlideData</code> model:</p>
  
  <pre><code>public interface ISlideData
  {
      public int Index { get; set; }
  
      public IContext Context { get; set; }
  }
  </code></pre>
  
  <p><code>IContext</code> model:</p>
  
  <pre><code>public interface IContext : IDictionary&lt;string, dynamic&gt;
  {
  }
  </code></pre>
  
  <p>The default model binder works fine with the exception of <code>SlideData.Context</code>, which can be an arbitrarily large/deep object.</p>
  
  <p>For example, <code>json.context.table</code> is deserialized into:</p>
  
  <pre><code>{
    'table[0][0]': 'Price',
    'table[0][1]': 'Revenue',
    ...
  }
  </code></pre>
  
  <p>Instead of:</p>
  
  <pre><code>{
    'table': [
      [...]
    ]
  }
  </code></pre>
  
  <p>I'm thinking I need to override <code>System.Web.Mvc.DefaultModelBinder#BindModel</code> for just the <code>SlideData.Context</code> property, but I'm not really sure where to start.</p>
  
  <p>Any help here would be much appreciated.</p>