Skip to content
This repository was archived by the owner on Jul 17, 2023. It is now read-only.

use fetch() instead of axios() - #101

Draft
bordalix wants to merge 3 commits into
vulpemventures:masterfrom
bordalix:remove_axios
Draft

bordalix wants to merge 3 commits into
vulpemventures:masterfrom
bordalix:remove_axios

Conversation

@bordalix

Copy link
Copy Markdown
Contributor

Why we need to stop using axios and start using fetch:

  • Google is enforcing Chrome extensions to adopt Manifest v3.
  • With Manifest v3 it is mandatory to use service workers instead of the background script.
  • Workers no longer provide XMLHttpRequest, but instead support the more modern fetch().
  • Since axios uses XMLHttpRequest, it will not work under a service worker.
  • So this module it will not work if included in a new Chrome extension.

@tiero please review

Comment thread src/network.ts Outdated
Comment thread src/network.ts Outdated
@tiero

tiero commented Jan 19, 2022

Copy link
Copy Markdown
Member

Looks good to me, although I would wait to merge for this change until we understand how we can move to manifest v3 safely (wasm support missing)

@tiero
tiero marked this pull request as draft September 27, 2022 12:03
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants