<ul dir="auto">
<li>[x ] I have searched the <a href="https://github.com/callemall/material-ui/issues">issues</a> of this repository and believe that this is not a duplicate.</li>
</ul>
<h2 dir="auto">Expected Behavior</h2>
<p dir="auto">There should be no error</p>
<h2 dir="auto">Current Behavior</h2>
<p dir="auto">The following error happens:</p>
<blockquote>
<p dir="auto">Menu.js:535 Uncaught TypeError: Cannot read property 'props' of undefined<br>
at Object.handleClickAway [as onClickAway] (Menu.js:535)<br>
at HTMLDocument.ClickAwayListener._this.handleClickAway</p>
</blockquote>
<h2 dir="auto">Steps to Reproduce (for bugs)</h2>
<ol dir="auto">
<li>Provide SelectField an empty array [] as child instead of array of MenuItem's.</li>
<li>Open this SelectField's dropdown. Empty dropdown is shown as there are no items to select.</li>
<li>Click away to close the dropdown. Error will appear in the console.</li>
</ol>
<p dir="auto">(the same happens if I provide undefined instead of empty array)</p>
<h2 dir="auto">Context</h2>
<p dir="auto">Perhaps it is intended I provide at least one MenuItem in the child array but empty array should be valid also as I don't want items in the dropdown in my context.</p>
<h2 dir="auto">Your Environment</h2>
<table role="table">
<thead>
<tr>
<th>Tech</th>
<th>Version</th>
</tr>
</thead>
<tbody>
<tr>
<td>Material-UI</td>
<td>0.19.4</td>
</tr>
</tbody>
</table>
<p dir="auto">Property 'ref' does not exist on type 'IntrinsicAttributes &amp; IconButtonProps &amp; { children?: ReactNode; }'</p>
<p dir="auto">This is the case for IconButton, but might be the case for others as well (didn't test any others).</p>


<ul class="contains-task-list">
<li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> I have searched the <a href="https://github.com/callemall/material-ui/issues">issues</a> of this repository and believe that this is not a duplicate.</li>
</ul>
<h2 dir="auto">Expected Behavior</h2>

<p dir="auto">The ref property should be available for any react component.</p>
<h2 dir="auto">Current Behavior</h2>

<p dir="auto">It is not, making TS complain with a 'Property 'ref' does not exist on type 'IntrinsicAttributes &amp; IconButtonProps &amp; { children?: ReactNode; }' when trying to add it.</p>
<h2 dir="auto">Steps to Reproduce (for bugs)</h2>

<p dir="auto">Create a tsx file that uses the following:</p>
<div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="      &lt;IconButton
        ref={node =&gt; { console.log(node); }}
      &gt;
      &lt;/IconButton&gt;"><pre class="notranslate"><code class="notranslate">      &lt;IconButton
        ref={node =&gt; { console.log(node); }}
      &gt;
      &lt;/IconButton&gt;
</code></pre></div>
<h2 dir="auto">Context</h2>
    
<h2 dir="auto">Your Environment</h2>

<table role="table">
<thead>
<tr>
<th>Tech</th>
<th>Version</th>
</tr>
</thead>
<tbody>
<tr>
<td>Material-UI</td>
<td>latest beta</td>
</tr>
<tr>
<td>React</td>
<td>16</td>
</tr>
<tr>
<td>browser</td>
<td>Chrome 62</td>
</tr>
<tr>
<td>ts</td>
<td>2.6.1</td>
</tr>
</tbody>
</table>