|
1 | 1 | import React from "react"
|
2 | 2 |
|
3 |
| -export type AsyncChildren<T> = (state: AsyncState<T>) => React.ReactNode | React.ReactNode |
4 |
| -export type InitialChildren<T> = (state: AsyncInitial<T>) => React.ReactNode | React.ReactNode |
5 |
| -export type PendingChildren<T> = (state: AsyncPending<T>) => React.ReactNode | React.ReactNode |
6 |
| -export type FulfilledChildren<T> = ( |
7 |
| - data: T, |
8 |
| - state: AsyncFulfilled<T> |
9 |
| -) => React.ReactNode | React.ReactNode |
10 |
| -export type RejectedChildren<T> = ( |
11 |
| - error: Error, |
12 |
| - state: AsyncRejected<T> |
13 |
| -) => React.ReactNode | React.ReactNode |
14 |
| -export type SettledChildren<T> = ( |
15 |
| - state: AsyncFulfilled<T> | AsyncRejected<T> |
16 |
| -) => React.ReactNode | React.ReactNode |
| 3 | +export type AsyncChildren<T> = ((state: AsyncState<T>) => React.ReactNode) | React.ReactNode |
| 4 | +export type InitialChildren<T> = ((state: AsyncInitial<T>) => React.ReactNode) | React.ReactNode |
| 5 | +export type PendingChildren<T> = ((state: AsyncPending<T>) => React.ReactNode) | React.ReactNode |
| 6 | +export type FulfilledChildren<T> = |
| 7 | + | ((data: T, state: AsyncFulfilled<T>) => React.ReactNode) |
| 8 | + | React.ReactNode |
| 9 | +export type RejectedChildren<T> = |
| 10 | + | ((error: Error, state: AsyncRejected<T>) => React.ReactNode) |
| 11 | + | React.ReactNode |
| 12 | +export type SettledChildren<T> = |
| 13 | + | ((state: AsyncFulfilled<T> | AsyncRejected<T>) => React.ReactNode) |
| 14 | + | React.ReactNode |
17 | 15 |
|
18 | 16 | export type PromiseFn<T> = (props: AsyncProps<T>, controller: AbortController) => Promise<T>
|
19 | 17 | export type DeferFn<T> = (
|
|
0 commit comments