UNPKG

website-validator

Version:
35 lines (34 loc) 1.05 kB
import { LinkLocation, UrlRole, Assertion, FoundPageFetchResult } from "./index.js"; import { DeepReadonly } from "ts-essentials"; export declare const getUrlsFromSitemap: (contents: string, type: "xml" | "txt") => Promise<{ readonly url: string; readonly role: { readonly type: "document"; }; readonly asserts: readonly [{ readonly type: "permanent"; }]; readonly location: { readonly type: "sitemapxml"; readonly urlsetIndex: number; readonly urlIndex: number; }; }[] | { readonly url: string; readonly role: { readonly type: "document"; }; readonly asserts: readonly [{ readonly type: "permanent"; }]; readonly location: { readonly type: "sitemaptxt"; readonly index: number; }; }[]>; export declare const getLinks: (url: string, role: DeepReadonly<UrlRole>, res: FoundPageFetchResult) => Promise<DeepReadonly<{ url: string; role: UrlRole; asserts: readonly Assertion[]; location: LinkLocation; }[]>>;