UNPKG

565 BTypeScriptView Raw
1import { ISanitizer } from './tokens';
2/**
3 * A class to sanitize HTML strings.
4 */
5export declare class Sanitizer implements ISanitizer {
6 /**
7 * Sanitize an HTML string.
8 *
9 * @param dirty - The dirty text.
10 *
11 * @param options - The optional sanitization options.
12 *
13 * @returns The sanitized string.
14 */
15 sanitize(dirty: string, options?: ISanitizer.IOptions): string;
16 private _options;
17}
18/**
19 * The default instance of an `ISanitizer` meant for use by user code.
20 */
21export declare const defaultSanitizer: ISanitizer;