The .setPromise() method currently only accepts a promise. This can be a little annoying to work with e.g. when using inline expressions to conditionally set the promise. Allow such expressions to resolve to undefined and make the types correctly reflect that an atom with such a returned api has a Promise: undefined type.
Description
The
.setPromise()
method currently only accepts a promise. This can be a little annoying to work with e.g. when using inline expressions to conditionally set the promise. Allow such expressions to resolve toundefined
and make the types correctly reflect that an atom with such a returned api has aPromise: undefined
type.