Module
React.Basic.Hooks.Aff
- Package
- purescript-react-basic-hooks
- Repository
- spicydonuts/purescript-react-basic-hooks
#useAff Source
useAff :: forall a key. Eq key => key -> Aff a -> Hook (UseAff key a) (Result a)
useAff
is used for asynchronous effects or Aff
. The asynchronous effect
is re-run whenever the key changes. If another Aff
runs when the key
changes before the previous async resolves, it will cancel the previous in
flight async effect.