title: How to download a zip on react?
body: <p>on nodejs I'm sending the file as follows:</p>
  
  <pre><code>res.sendFile(fileName,{ root: path.join(__dirname, '../') });
  </code></pre>
  
  <p>on react i have been triying to dowload the file with axios with no success:</p>
  
  <pre><code>let dowloadGet = async (url, auth) =&gt; 
  await axiosDownload.get(url, { headers: { 'Authorization': `Bearer ${auth}` }, responseType: 'blob' });
  
    let response = await API.get(`${this.state.BE_route}/download_script_bytest/${this.props.test._id}`, this.props.idToken)
  
    const url = window.URL.createObjectURL(new Blob([response.data], {type:'application/zip'}));
    const link = document.createElement('a');
    link.href = url;
    link.setAttribute('download', 'file.zip');
    document.body.appendChild(link);
    link.click();
    link.parentNode.removeChild(link);
  </code></pre>