MCPcopy Create free account
hub / github.com/cure53/DOMPurify / _createTrustedHTML

Function _createTrustedHTML

src/purify.ts:358–367  ·  view source on GitHub ↗
(html: string)

Source from the content-addressed store, hash-verified

356 };
357
358 const _createTrustedHTML = function (html: string): string {
359 _assertNotInTrustedTypesPolicy();
360
361 IN_TRUSTED_TYPES_POLICY++;
362 try {
363 return trustedTypesPolicy.createHTML(html);
364 } finally {
365 IN_TRUSTED_TYPES_POLICY--;
366 }
367 };
368
369 /* Sign string output when a policy is active and the caller asked for it */
370 const _signOutput = function (html: string): string {

Callers 4

_signOutputFunction · 0.85
_parseConfigFunction · 0.85
_initDocumentFunction · 0.85

Calls 1

Tested by

no test coverage detected