import { StringMap } from '../core';
/**
 * Defines how a error object (validator key, error object, the control object) should be mapped to string.
 */
export interface ErrorMapperInterface {
    /**
     * Maps an error to a string.
     * @param {string} key the error key. i.e., required, etc
     * @param error the error object
     * @param control control Object (AbstractControl for Angular, NgModel for AngularJS)
     * @returns {string}
     */
    map(key: string, error?: unknown, control?: unknown): string;
}
export declare type ErrorsMapperFn = (error: Record<string, unknown>) => string;
export declare type ErrorMapper = ErrorMapperInterface | StringMap;
