title: Why can't a react stateless function return an array?
body: <p>Here's my stateless function that tries to return an array of elements: </p>
  
  <pre><code>function DeliveryPreference (props) {
    return [
        &lt;h4&gt;
          Delivery Preference
          &lt;/h4&gt;,
          &lt;div className='yesNoCheckbox'&gt;
            &lt;input type="radio" value={'tube'} onChange={props.onChange} id='tube' checked={props.value === 'tube'}/&gt; &lt;label htmlFor='tube'&gt;Tube&lt;/label&gt; &lt;br/&gt;
            &lt;input type="radio" value={'plate'} onChange={props.onChange} id='plate' checked={props.value === 'plate'}/&gt; &lt;label htmlFor='plate'&gt;Plate&lt;/label&gt;&lt;br/&gt;
          &lt;/div&gt;
    ];
  }
  </code></pre>
  
  <p>Can anyone explain why I can't do that, and/or provide a work-around? </p>
  
  <p>Thanks very much!</p>
  
  <p>Edit: 
  Here's a minimal example of the error:</p>
  
  <pre><code>function App (props) {
      return [
      &lt;div&gt;1&lt;/div&gt;,
      &lt;div&gt;2&lt;/div&gt;,
      ]
  }
  
  
  ReactDOM.render( 
      &lt;App/&gt;
      , document.getElementById('root')
  );
  </code></pre>