export const isPromise = < T > ( value ) : value is Promise < T > => { return ( value instanceof Promise || ( value !== null && ( typeof value === 'object' || typeof value === 'function' ) && typeof value . then === 'function' ) ) ; } ;