import type { JSDOM } from "jsdom"; export interface JsonLdArticle { title?: string; text?: string; } export interface JsonLdScan { present: boolean; article: JsonLdArticle | null; } /** * Scan a document's JSON-LD blocks for Article schema, reporting presence and * extractable content as separate facts. * * They must stay separate. `applyPostExtract` previously reported presence as * `result.source === "json_ld"` — true only when JSON-LD supplied the page * body, which additionally requires an `articleBody` of at least * MIN_JSONLD_BODY_CHARS. Sites overwhelmingly publish headline and metadata * without a body, so the domain DB recorded json_ld_article present on 0 of 111 * sampled pages while og:title, checked directly against the HTML, read 40% on * the same sample. shouldSkipJsonLdPostExtract then latched those domains off * after five samples, making the false negative self-sustaining. */ export declare function scanJsonLd(dom: JSDOM): JsonLdScan; export declare function extractJsonLdArticle(dom: JSDOM): JsonLdArticle | null;