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

Abort() function #3

Closed
ACCTFORGH opened this issue Dec 10, 2015 · 8 comments
Closed

Abort() function #3

ACCTFORGH opened this issue Dec 10, 2015 · 8 comments

Comments

@ACCTFORGH
Copy link

Is abort() or similar function available? Fetch is known to not have abort() in place. I am considering to use frisbee in React Native but am thinking to cancel the connections when component unmounts. Or, could it be that, for fetch-based libraries, it is not necessary to have abort() function in place?

@niftylettuce
Copy link
Collaborator

@rmevans9 @ACCTFORGH can any of you make this PR to add this in?

@niftylettuce
Copy link
Collaborator

@ACCTFORGH I use it in React Native - it would be cool to have this abort() functionality when component unmounts!

@niftylettuce
Copy link
Collaborator

@ACCTFORGH see whatwg/fetch#27

@ACCTFORGH
Copy link
Author

@niftylettuce Thanks!

@zsherman
Copy link

@niftylettuce seems like this landed in whatwg/fetch#523

@Noitidart
Copy link

@niftylettuce may you please share how you do the abort in react-native, I am trying to do the same in RN.

@niftylettuce
Copy link
Collaborator

@Noitidart I've never done it - I just meant I use frisbee in React Native

Anyone here want to submit a PR that adds this functionality/method to Frisbee?

https://developer.mozilla.org/en-US/docs/Web/API/AbortController

https://www.npmjs.com/package/abortcontroller-polyfill

@niftylettuce
Copy link
Collaborator

I've released v2.0.10 to NPM with support for this!

See #83 (comment)

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

5 participants