Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore.

15 St Margarets, NY 10033
(+381) 11 123 4567



Execute And Watch Async Function In React

This is a React hook for handling asynchronous tasks, such as backend API calls.

How to use it:

1. Install and import the react-async-watcher.

# Yarn
$ yarn add react-async-watcher

$ npm i react-async-watcher
import { useAsyncWatcher } from 'react-async-watcher';

2. Basic usage:

const { execute, reset, status, result, error } = useAsyncWatcher()
execute(async () => {
  // do whatever you want


Execute And Watch Async Function In React

Download Details:

Author: xralphack

Live Demo: View The Demo

Download Link: Download The Source Code

Official Website: https://github.com/xralphack/react-async-watcher

License: MIT

Credit: Source link

Previous Next
Test Caption
Test Description goes like this