Is there a way to save a PDF file from a binary response received through an axios get request?
When making the request, I include the following headers:
const config: AxiosRequestConfig = {
headers: {
Accept: 'application/pdf',
responseType: 'arraybuffer',
},
};
After receiving the binary response, I would like to download it using the file-saver library, specifically its saveAs function.