Kotlin Wrappers API Reference
Toggle table of contents
common
js
Platform filter
common
js
Switch theme
kotlin-js
/
js.promise
/
PromiseLike
Promise
Like
interface
PromiseLike
<
out
T
:
JsAny
?
>
:
PromiseResult
<
T
>
(
source
)
Inheritors
Promise
Members
Members & Extensions
Functions
await
Link copied to clipboard
inline suspend
fun
<
T
:
JsAny
?
>
PromiseLike
<
T
>
.
await
(
)
:
T
inline suspend
fun
<
T
:
JsAny
?
>
PromiseResult
<
T
>
.
await
(
)
:
T
flat
Then
Link copied to clipboard
abstract
fun
<
R
:
JsAny
?
>
flatThen
(
onFulfilled
:
(
T
)
->
PromiseResult
<
R
>
)
:
PromiseLike
<
R
>
abstract
fun
<
R
:
JsAny
?
>
flatThen
(
onFulfilled
:
(
T
)
->
PromiseResult
<
R
>
,
onRejected
:
(
JsErrorLike
?
)
->
PromiseResult
<
R
>
)
:
PromiseLike
<
R
>
then
Link copied to clipboard
abstract
fun
<
R
:
JsAny
?
>
then
(
onFulfilled
:
(
T
)
->
R
)
:
PromiseLike
<
R
>
abstract
fun
<
R
:
JsAny
?
>
then
(
onFulfilled
:
(
T
)
->
R
,
onRejected
:
(
JsErrorLike
?
)
->
R
)
:
PromiseLike
<
R
>
then
To
Link copied to clipboard
inline
fun
<
T
:
JsAny
?
>
PromiseLike
<
T
>
.
thenTo
(
continuation
:
Continuation
<
T
>
)
to
Promise
Link copied to clipboard
inline
fun
<
T
:
JsAny
?
>
PromiseResult
<
T
>
.
toPromise
(
)
:
Promise
<
T
>
to
Result
Link copied to clipboard
js
suspend
fun
<
T
>
PromiseLike
<
T
>
.
toResult
(
)
:
Result
<
T
>