这是一个异步值的接口,它包含了一个value字段和一个resolved字段 value字段表示异步操作的结果,resolved字段表示异步操作是否已经完成
Name |
---|
T |
AsyncErrorValue
<T
| null
>new AsyncPromiseValue<T
>(promise
)
Name |
---|
T |
Name | Type |
---|---|
promise |
Promise <T > |
Private
_reason: any
Private
_status: any
Private
_value: any
get
error(): any
any
get
errored(): boolean
boolean
get
resolved(): boolean
boolean
get
status(): "pending"
| "fulfilled"
| "rejected"
"pending"
| "fulfilled"
| "rejected"
get
value(): null
| T
null
| T