web-crawling-utils
Version:
Common useful utils for web crawling and automation scripts
16 lines (15 loc) • 381 B
TypeScript
interface ValidationRules {
required?: boolean;
type?: "string" | "number" | "boolean" | "array" | "object" | "date" | "enum" | `array:${string}`;
minLength?: number;
maxLength?: number;
min?: number;
max?: number;
pattern?: RegExp;
enum?: any[];
properties?: Schema;
}
export interface Schema {
[key: string]: ValidationRules;
}
export {};