title: Download an epub file through axios & react-file-download lbraries in reactjs
body: <p>I am trying to fetch an epub file from my server using axios and <a href="https://www.npmjs.com/package/react-file-download" rel="nofollow noreferrer">react-file-download</a>. The download code looks as follows -</p>
  
  <pre><code>const FileDownload = require('react-file-download');
  export const handleDownload = (url, bookName) =&gt; {
    axios.get(url).then((res) =&gt; {
      FileDownload(res.data, bookName+'.epub');
    });
  } 
  </code></pre>
  
  <p>The file is downloaded. I see different size on disc for different books. But they just don't open. What am i missing? </p>