(textToDecode: string)
| 72 | } |
| 73 | |
| 74 | function createHtml4DecodeMethods(textToDecode: string) { |
| 75 | const strict: DecodeOptions = {level: 'html4', scope: 'strict'}; |
| 76 | const body: DecodeOptions = {level: 'html4', scope: 'body'}; |
| 77 | const attribute: DecodeOptions = {level: 'html4', scope: 'attribute'}; |
| 78 | return { |
| 79 | 'html-entities.decode - html4, strict': () => decode(textToDecode, strict), |
| 80 | 'html-entities.decode - html4, body': () => decode(textToDecode, body), |
| 81 | 'html-entities.decode - html4, attribute': () => decode(textToDecode, attribute), |
| 82 | '(old) Html4Entities.decode': () => html4Entities.decode(textToDecode) |
| 83 | }; |
| 84 | } |
| 85 | |
| 86 | function createXmlEncodeMethods(textToEncode: string) { |
| 87 | const nonAsciiPrintable: EncodeOptions = {level: 'xml', mode: 'nonAsciiPrintable'}; |
no test coverage detected