@types/sanitizer
TypeScript icon, indicating that this package has built-in type declarations

0.0.31 • Public • Published

Installation

npm install --save @types/sanitizer

Summary

This package contains type definitions for sanitizer (https://github.com/theSmaw/Caja-HTML-Sanitizer).

Details

Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/sanitizer.

index.d.ts

export interface ISaxHandler {
    startTag(name: string, attribs: string[], param: any): void;
    endTag(name: string, param: any): void;
    pcdata(text: string, param: any): void;
    cdata(text: string, param: any): void;
    rcdata(text: string, param: any): void;
    comment(text: string, param: any): void;
    startDoc(param: any): void;
    endDoc(param: any): void;
}

export declare function escape(s: string): string;

export declare function makeSaxParser(yourHandler: ISaxHandler): (...any: any[]) => any;

export declare function normalizeRCData(s: string): string;

export declare function sanitize(s: string): string;

export declare function unescapeEntities(s: string): string;

Additional Details

  • Last updated: Tue, 07 Nov 2023 15:11:36 GMT
  • Dependencies: none

Credits

These definitions were written by Dave Taylor.

Dependencies (0)

    Dev Dependencies (0)

      Package Sidebar

      Install

      npm i @types/sanitizer

      Weekly Downloads

      7,612

      Version

      0.0.31

      License

      MIT

      Unpacked Size

      3.88 kB

      Total Files

      5

      Last publish

      Collaborators

      • types