title: How pass arguments via require to material avatar
body: <pre><code>import Avatar from '@material-ui/core/Avatar';
  </code></pre>
  
  <p>This code works:</p>
  
  <pre><code>&lt;Avatar alt="user 4" src={require('Assets/img/user-1.jpg')} className="size-80 rounded-circle border-info rct-notify" /&gt;
  </code></pre>
  
  <p>But I need to pass variable, this code doesn't work :</p>
  
  <pre><code>{line.icon != null &amp;&amp; &lt;Avatar alt="user 3" src={require(line.icon)} className="size-80 rounded-circle border-warning rct-notify" /&gt;}
  </code></pre>
  
  <p>Error:</p>
  
  <pre><code>Uncaught Error: Cannot find module 'Assets/img/user-3.jpg'
  </code></pre>