UNPKG

@jupyterlab/apputils

Version:
31 lines (30 loc) 826 B
import { ISanitizer } from './tokens'; /** * A class to sanitize HTML strings. */ export declare class Sanitizer implements ISanitizer { /** * Sanitize an HTML string. * * @param dirty - The dirty text. * * @param options - The optional sanitization options. * * @returns The sanitized string. */ sanitize(dirty: string, options?: ISanitizer.IOptions): string; /** * Set the allowed schemes * * @param scheme Allowed schemes */ setAllowedSchemes(scheme: Array<string>): void; private _options; } /** * The default instance of an `ISanitizer` meant for use by user code. * * @deprecated It will be removed in JupyterLab v4. You should request the `ISanitizer` in * your plugin instead. */ export declare const defaultSanitizer: ISanitizer;