@promptbook/remote-client
Version:
Promptbook: Turn your company's scattered knowledge into AI ready books
13 lines (12 loc) • 497 B
TypeScript
import type { Takeable } from './Takeable';
/**
* Represents any value with take chain functionality
*
* @private util of `@promptbook/color`
* @deprecated [🤡] Use some better functional library instead of `TakeChain`
*/
export type WithTake<TValue extends Takeable> = TValue & ITakeChain<TValue>;
export type ITakeChain<TValue extends Takeable> = {
readonly value: TValue;
then<TResultValue extends Takeable>(callback: (value: TValue) => TResultValue): WithTake<TResultValue>;
};