1
Fork 0
mirror of https://github.com/pds-nest/nest.git synced 2024-11-25 06:24:19 +00:00

🗑 Remove unused hook useAsyncEffect

This commit is contained in:
Steffo 2021-05-22 04:36:08 +02:00
parent 36f7f76372
commit f27304e34c
Signed by: steffo
GPG key ID: 6965406171929D01

View file

@ -1,17 +0,0 @@
/* eslint-disable */
import { useEffect } from "react"
/**
* {@link useEffect}, but with an async effect.
*
* @warning Breaks `react-hooks/exaustive-deps`.
*
* @param effect - The async effect.
* @param deps - The dependencies of the hook.
*/
export default function useAsyncEffect(effect, deps) {
useEffect(() => {
effect()
}, [effect, ...deps])
}