Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

window is undefined error using axios in a WebWorker #1161

Closed
owap opened this issue Nov 2, 2017 · 1 comment
Closed

window is undefined error using axios in a WebWorker #1161

owap opened this issue Nov 2, 2017 · 1 comment

Comments

@owap
Copy link
Contributor

owap commented Nov 2, 2017

I created #1160 when trying to troubleshoot the axios instance in my webworker.

I saw this tweet from 2015; is there anything special I need to do to be able to make HTTP requests in the web worker?

After patching locally with #1160, i'm getting 401s now, which we have overcome in the rest of our (non web-worker'd app) by setting the default axios headers:

Regardless, the window bug (addressed in #1160) still needs patching (on my machine) 👍

Thanks!

Edit: Works great as long as #1160 is merged 👍

@owap owap changed the title Example for using axios in a WebWorker window is undefined error using axios in a WebWorker Nov 3, 2017
@nickuraltsev
Copy link
Member

Fixed via #1160

@axios axios locked and limited conversation to collaborators May 22, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants