Rocky_Mountain_Vending/.pnpm-store/v10/files/ac/e70175672d94cf02e6cf4f67604804d1fb1c95855ba2205a032881b2ff85a386d59ea372b8549f2dff63bdde8184f35985cacb8af38ff24948e7e05830f8a2
DMleadgen 46d973904b
Initial commit: Rocky Mountain Vending website
Next.js website for Rocky Mountain Vending company featuring:
- Product catalog with Stripe integration
- Service areas and parts pages
- Admin dashboard with Clerk authentication
- SEO optimized pages with JSON-LD structured data

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-12 16:22:15 -07:00

74 lines
1.9 KiB
Text

interface TldsAllow {
readonly allow: Set<string>;
}
interface TldsDeny {
readonly deny: Set<string>;
}
export interface DomainOptions {
/**
* Determines whether Unicode characters are allowed.
*
* @default true
*/
readonly allowUnicode?: boolean;
/**
* Determines whether underscore (_) characters are allowed.
*
* @default false
*/
readonly allowUnderscore?: boolean;
/**
* The maximum number of domain segments (e.g. `x.y.z` has 3 segments) allowed.
*
* @default Infinity
*/
readonly maxDomainSegments?: number;
/**
* The minimum number of domain segments (e.g. `x.y.z` has 3 segments) required.
*
* @default 2
*/
readonly minDomainSegments?: number;
/**
* Top-level-domain options
*
* @default true
*/
readonly tlds?: TldsAllow | TldsDeny;
/**
* Allows passing fully qualified domain (ends with a period)
*
* @default false
*/
readonly allowFullyQualified?: boolean;
}
export interface Analysis {
/**
* The reason validation failed.
*/
error: string;
/**
* The error code.
*/
code: string;
}
/**
* Analyzes a string to verify it is a valid domain name.
*
* @param domain - the domain name to validate.
* @param options - optional settings.
*
* @return - undefined when valid, otherwise an object with single error key with a string message value.
*/
export declare function analyzeDomain(domain: string, options?: DomainOptions): Analysis | null;
/**
* Analyzes a string to verify it is a valid domain name.
*
* @param domain - the domain name to validate.
* @param options - optional settings.
*
* @return - true when valid, otherwise false.
*/
export declare function isDomainValid(domain: string, options?: DomainOptions): boolean;
export declare function validateDomainOptions(options: DomainOptions): void;
export {};