File tree Expand file tree Collapse file tree 1 file changed +9
-1
lines changed Expand file tree Collapse file tree 1 file changed +9
-1
lines changed Original file line number Diff line number Diff line change @@ -411,14 +411,22 @@ external displayName: component<'props> => option<string> = "displayName"
411
411
412
412
// Actions
413
413
414
- type transitionFunction = unit => promise < unit >
414
+ type transitionFunction = unit => unit
415
415
416
416
type transitionStartFunction = transitionFunction => unit
417
417
418
418
/** `useTransition` is a React Hook that lets you render a part of the UI in the background. */
419
419
@module ("react" )
420
420
external useTransition : unit => (bool , transitionStartFunction ) = "useTransition"
421
421
422
+ type transitionAsyncFunction = unit => promise <unit >
423
+
424
+ type transitionAsyncStartFunction = transitionAsyncFunction => unit
425
+
426
+ /** `useTransitionAsync` is a React Hook that lets you render a part of the UI in the background. */
427
+ @module ("react" )
428
+ external useTransitionAsync : unit => (bool , transitionAsyncStartFunction ) = "useTransition"
429
+
422
430
type action <'state , 'payload > = ('state , 'payload ) => promise <'state >
423
431
424
432
type formAction <'formData > = 'formData => promise <unit >
You can’t perform that action at this time.
0 commit comments