@studiohyperdrive/ngx-forms
Version:
An Angular package to help with complex forms and their validation.
10 lines (9 loc) • 542 B
TypeScript
import { ValidatorFn } from '@angular/forms';
/**
* A FormGroup validator to check whether a start and end date are chronologically correct
*
* @param startControlKey - The key of the control containing the start date value
* @param endControlKey - The key of the control containing the end date value
* @param format - Optional format of the dates provided by the controls, by default yyyy-MM-dd
*/
export declare const chronologicalDatesValidator: (startControlKey: string, endControlKey: string, dateFormat?: string) => ValidatorFn;