How to use srcset 2x with React and Webpack?
<p>From this answer</p>

<p><a href="https://stackoverflow.com/questions/32612912/dynamically-add-images-react-webpack/35454832#35454832">Dynamically Add Images React Webpack</a></p>

<p>I know, how to use usual image src with React + Webpack.</p>

<p>How can I get the same result with srcset 2x having a space inside?</p>

<p>It looks like I can't import from a string like this:</p>

<p>import picture from './temp/picture@2x.jpg 2x';</p>

<p>It breaks, probably because of a space inside.</p>

<p>I tried to look for some plugin, but this </p>

<p><a href="https://github.com/herrstucki/responsive-loader" rel="noreferrer">https://github.com/herrstucki/responsive-loader</a></p>

<p>clearly says that 2x is not supported.</p>

<p>And this</p>

<p><a href="https://www.npmjs.com/package/srcset-loader" rel="noreferrer">https://www.npmjs.com/package/srcset-loader</a></p>

<p>doesn't mention 2x at all, so I guess it doesn't support it too.</p>

<p>So, is there any way to use srcset 2x here?</p>