title: When to use React createFragment?
body: <p>I'm rendering a <code>ListView</code> in React Native, managed to fix this React warning but I don't understand how and why it works: </p>
  
  <blockquote>
    <p>Warning: Any use of a keyed object should be wrapped in React.addons.createFragment(object) before being passed as a child.</p>
  </blockquote>
  
  <pre><code>// This array generates React Fragment warning.
  var data1 = [{name: "bob"}, {name:"john"}]
  
  // This array works, no warnings.
  var data2 = [React.addons.createFragment({name: "bob"}),
               React.addons.createFragment({name: "john"})]
  
  // This also works, no warnings.
  var data3 = ["bob", "john"]
  
  class Listings extends React.Component {
    constructor(props) {
      super(props)
      ds = new ListView.DataSource({rowHasChanged: (r1, r2) =&gt; r1 !== r2})
  
      this.state = {
        dataSource: ds.cloneWithRows(data),
      }
    }
    render() {
      return (
         &lt;ListView
           dataSource={this.state.dataSource} 
           renderRow={(rowData) =&gt; &lt;Text&gt;{rowData}&lt;/Text&gt;} /&gt;
      )
    }
  }
  </code></pre>
  
  <p>What is a React Fragment? When is it needed in React? Why does a keyed object cause this warning?</p>