UNPKG

@adpt/cli

Version:
19 lines 681 B
import { AnyObject } from "@adpt/utils"; import { Schema } from "./schema"; export interface GetValOptions { /** * Return the default value from the schema if the requested property is * not present on the object. */ useDefault?: boolean; /** * A transformation to apply to the property name before using it as an * index into the object. */ propTransform?: (prop: string) => string; } export declare function getValIfSet<S extends Schema, Prop extends keyof S>(prop: Prop, obj: AnyObject, schema: S, options?: GetValOptions): { parsed: string | number | boolean; store: {}; } | undefined; //# sourceMappingURL=get_val.d.ts.map