method RichContentProvider.fetch
RichContentProvider.fetch(url: string): Promise<RichContent>

Returns the preview of url, which ends up in the dump's rich_content or the create form's preview. It rejects when the page can't be fetched or answers with an error status, and the service then falls back to a stub. A page that isn't HTML yields a preview without metadata. The service tidies what it returns, so a provider leaves text as the page wrote it.

Parameters

url: string

Return Type

Promise<RichContent>

Usage

import { type RichContentProvider } from "api/remote/providers/provider.ts";