title: Can I import a png/jpg image like a component? React.js
body: <p>I am doing a personal project in react.js but I would like to write clean code. Is there a way to import a png image into a component or something like that? I tried to convert it into a svg image but most of the converter pages do not work. If It can not be converted. You can answer with a nice converter page. thanks</p>
  <p>for example</p>
  <pre><code>import { ReactComponent as AppIcon } from '../assets/img/icon_app.svg
  </code></pre>
  <p>and import it like this</p>
  <pre><code>&lt;AppIcon /&gt;
  </code></pre>