Installation | useTask


You can install useTask through NPM by adding it to your dependencies:

# Using yarn
yarn add use-task

# Using NPM
npm install --save use-task

Global Dependency: AbortController

Internally, useTask makes use of the AbortController API that was introduced as part of the effort to create a means for cancelling fetch. It should work in all evergreen browsers, but if that does not fit your use case, you can find information on polyfilling it here.