-
-
Notifications
You must be signed in to change notification settings - Fork 11.2k
Closed
Description
Describe the bug
When using axios to get a local file (file://...
) I get status code 0 as if there's a CORS issue. This didn't happen using version 0.18.0 so I assume that this is a bug?
To Reproduce
Get a local file. In my case I wanted to get a PDF as an array buffer.
axios("file://...", {
responseType: 'arraybuffer'
headers: {
Accept: 'application/pdf'
}
}).then(..)
Expected behavior
Just like in version 0.18.0 version I should get a 200 response.
Environment:
- Axios Version 0.19.0
- OS: Windows 10
- Browser: EO Webbrowser (Chromium)
- Browser Version: 19.1.95 (Chromium ~70)
- Additional Library Versions: React 16.8.6
Additional context/Screenshots
Need to build and run index.html locally so you're making the request from file:// as well.
Metadata
Metadata
Assignees
Labels
No labels