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

Use fetch instead of superagent #150

Open
LaurensRietveld opened this issue Feb 10, 2020 · 0 comments
Open

Use fetch instead of superagent #150

LaurensRietveld opened this issue Feb 10, 2020 · 0 comments

Comments

@LaurensRietveld
Copy link
Contributor

We use superagent for all http requests. This is a left-over from the old yasgui version. Let's use the native fetch api instead.
This should solve #144 as well, as fetch doesn't do any 'magic' response body parsing

ptgolden added a commit to ptgolden/rdf-ui that referenced this issue Mar 31, 2022
I noticed dbpedia being queried in the network tab when running the demo-- it seems like that's a consequence of `yasqe`'s [default configuration](https://github.com/TriplyDB/Yasgui/blob/685d1f32a01a16eb17ce480d1766941acda9a416/packages/yasqe/src/defaults.ts#L132-L145>).

This commit aborts that request before it's able to be sent, using the [`abort` method](https://visionmedia.github.io/superagent/#aborting-requests) of the HTTP request library that `yasqe` uses.

This will stop working if `yasqe` [moves away from that library](TriplyDB/Yasgui#150) and uses `fetch` instead.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant