import { type Kind } from "../../common/kind"; import { type Right } from "./create"; export declare const successKind: import("../../common/kind").KindHandler>; /** * @deprecated use successKind */ export declare const eitherSuccessKind: import("../../common/kind").KindHandler>; type _Success = (Right<"success", GenericValue> & Kind); export interface Success extends _Success { } /** * @deprecated use Success */ export type EitherSuccess = Success; /** * Readable shortcut to create an Right with the literal info "success". Ideal for functions that return only one type of success. * * Signature: `success(value)` → returns a value * * The input value is not mutated. * * ```ts * const input = " duplo "; * * const result = pipe( * input, * S.trim, * whenElse( * (value) => equal(S.length(value), 0), * E.error, * E.success, * ), * ); * * // type: E.Error | E.Success * ``` * * @see https://utils.duplojs.dev/en/v1/api/either/success * * @namespace E * */ export declare function success(value: GenericValue): Success; export {};