Skip to content

Commit 1642393

Browse files
committedJul 8, 2019
some docs for useEffect
1 parent 3f3cf28 commit 1642393

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed
 

‎src/React/Basic/Hooks.purs

+3-1
Original file line numberDiff line numberDiff line change
@@ -113,6 +113,8 @@ useState initialState = Render do
113113

114114
foreign import data UseEffect :: Type -> Type -> Type
115115

116+
-- | The effect will be run when the component is mounted, and the effect
117+
-- | returned from the function will be run on cleanup
116118
useEffect
117119
:: forall key
118120
. Eq key
@@ -367,4 +369,4 @@ foreign import useEqCache_
367369
. EffectFn2
368370
(Fn2 a a Boolean)
369371
a
370-
a
372+
a

0 commit comments

Comments
 (0)
Please sign in to comment.