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

Support for Fetch API #93

Closed
geiseri opened this issue Dec 8, 2018 · 4 comments
Closed

Support for Fetch API #93

geiseri opened this issue Dec 8, 2018 · 4 comments

Comments

@geiseri
Copy link

geiseri commented Dec 8, 2018

Right now it seems that Axios is not interested in supporting the Fetch API standard. While it is quite new and not widely supported it has several key features for PWAs that help with offline first activities and caching API calls. It also has support for Blobs which are becoming more popular for texture assets. From the API it doesn't look like there are a lot of dependencies on the behaviors of axios, but the API is different enough that it might make it hard to have a drop-in replacement. Thoughts?

@christianmalek
Copy link
Owner

At the moment the usage of axios is "hard coded" in vuex-rest-api. Of course it would be possible to implement interfaces and make it possible to also use the fetch API. I'll have to research how far this code change would benefit vuex-rest-api.

I'll also consider substituting axios with the fetch API if this makes sense.

@geiseri
Copy link
Author

geiseri commented Dec 9, 2018

I did a cursory look and it seemed like it might be a bit more invasive. On the plus side with a polyfill Fetch could become the default and no lose any browser support. The key thing I need would be the ability to support offline and background sync.

@christianmalek
Copy link
Owner

Thanks for your additional feedback.

@christianmalek
Copy link
Owner

I'll close this. Feel free to open it again.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants