UNPKG

@vulppi/env

Version:
23 lines (20 loc) 932 B
// Generated by dts-bundle-generator v9.5.1 export declare const COMMENT_LINE_START: RegExp; export declare const PROPERTY_LINE_START: RegExp; export declare const PROPERTY_LINE_VALIDATION: RegExp; /** * Parses the input text into an array containing key-value pairs. * * @param {string} txt - The input text to parse * @return {EnvListItem[]} An array of objects with key, value, and description */ export declare function parseEnvToList(txt: string): EnvListItem[]; /** * Parses an array of objects containing key-value pairs and descriptions into a string representation of an environment file. * * @param {EnvListItem[]} env - An array of objects containing key-value pairs and descriptions. * @return {string} A string representation of an environment file. */ export declare function parseListToEnv(env: EnvListItem[]): string; export type EnvListItem = Record<"key" | "value" | "description", string>; export {};