UNPKG

727 BTypeScriptView Raw
1export as namespace striptags
2
3export = striptags
4
5/**
6 * Creates an array of elements split into groups the length of size. If collection can’t be split evenly, the
7 * final chunk will be the remaining elements.
8 *
9 * @param html The text to process.
10 * @param allowedTags Tags which aren't removed
11 * @param tagReplacement Removed tags are replaced with this
12 * @return Returns the input string, sans any html tags that weren't allowed
13 */
14declare function striptags(
15 html: string,
16 allowedTags?: string | string[],
17 tagReplacement?: string
18): string
19
20declare namespace striptags {
21 export const init_streaming_mode: (
22 allowedTags?: string | string[],
23 tagReplacement?: string
24 ) => (html: string) => string
25}