API reference: @salmonui/rich-text
SanitizeElementinterface
import type { SanitizeElement } from '@salmonui/rich-text';interface SanitizeElement {
readonly tag: string;
readonly attrs: Readonly<Record<string, string>>;
readonly parent: string | null;
}
A sanitized element as the sanitize hook sees it (read-only copy).
| Name | Signature | Description |
|---|---|---|
tag | readonly tag: string; | Lowercase tag name from the vocabulary ( |
attrs | readonly attrs: Readonly<Record<string, string>>; | The attributes that survived the built-in rules. |
parent | readonly parent: string | null; | Tag of the sanitized parent element, or null at the top level. |