/** * Helpers for safely emitting XML from arbitrary input. */ /** * Escape XML entities in a text/attribute value and strip the disallowed * C0 control characters and `DEL` covered by `ILLEGAL_XML_CHARS` (XML 1.0 * ยง2.2). Surrogate halves and noncharacters such as U+FFFE/U+FFFF are * intentionally NOT filtered here. Safe for `VALUE` and * `attr="VALUE"` insertion. */ export declare function escapeXml(value: unknown): string; /** * Convert an arbitrary string into a safe XML element name using a * conservative ASCII-only subset of XML naming rules. * * This helper allows names that start with `A-Z`, `a-z`, or `_`, followed * by zero or more `A-Z`, `a-z`, `0-9`, `_`, `.`, or `-` characters. Any * other character is replaced with `_`, including namespace separators * (`:`) and non-ASCII / Unicode name characters that the full XML 1.0 * NameStartChar / NameChar productions would allow. An empty/invalid * result falls back to `_`. */ export declare function sanitizeXmlName(name: string): string;