import type { FormValue } from './types';
export declare function invariant(expectedCondition: boolean, message: string): asserts expectedCondition;
export declare function generateId(): string;
export declare function clone<Data>(data: Data): Data;
/**
 * Check if the value is a plain object
 */
export declare function isPlainObject(obj: unknown): obj is Record<string | number | symbol, unknown>;
/**
 * A utility function that performs a deep equality check between two values.
 * It handles plain objects, arrays, and primitive values only.
 */
export declare function deepEqual(left: unknown, right: unknown): boolean;
export declare function stripFiles<Type extends string | number | boolean | File | null>(value: Record<string, FormValue<Type>>): Record<string, FormValue<Exclude<Type, File>>>;
/**
 * Helper to get readable type name for error messages
 */
export declare function getTypeName(value: unknown): string;
/**
 * Combines multiple regex patterns into a single HTML pattern attribute.
 *
 * This is done by putting each input pattern into a lookahead assertion
 * and stripping all flags.
 *
 * Returns undefined if any pattern is case-insensitive, since transforming
 * it to a case-sensitive pattern is a non-trivial operation.
 *
 * Example: [/[A-Z]/, /[0-9]/] -> '^(?=.*(?:[A-Z]))(?=.*(?:[0-9])).*$'
 */
export declare function serializeHtmlPattern(pattern: RegExp | RegExp[]): string | undefined;
//# sourceMappingURL=util.d.ts.map