0.55.1.json

[
  {
    "path": "package/esm/vs/base/browser/domSanitize.js",
    "hits": [
      "3: import purify from './dompurify/dompurify.js';",
      "123:  * Hooks dompurify using `afterSanitizeAttributes` to check that all `href` and `src`",
      "127:     purify.addHook('afterSanitizeAttributes', (node) => {",
      "149:     // We sanitize the src/href attributes later if needed",
      "155:  * @param untrusted The HTML string to sanitize.",
      "158:  * @returns A sanitized string of html.",
      "160: function sanitizeHtml(untrusted, config) {",
      "183:         // All attr names are lower-case in the sanitizer hooks",
      "213:             purify.addHook('uponSanitizeElement', replaceWithPlainTextHook);",
      "216:             purify.addHook('uponSanitizeAttribute', (node, e) => {",
      "234:             return purify.sanitize(untrusted, {",
      "240:             return purify.sanitize(untrusted, {",
      "247:         purify.removeAllHooks();",
      "251: const replaceWithPlainTextHook = (node, data, _config) => {",
      "256:                 // Workaround for https://github.com/cure53/DOMPurify/issues/1005",
      "312: export { basicMarkupHtmlTags, convertTagToPlaintext, defaultAllowedAttrs, safeSetInnerHtml, sanitizeHtml };"
    ]
  },
  {
    "path": "package/esm/vs/base/browser/markdownRenderer.js",
    "hits": [
      "15: import { basicMarkupHtmlTags, safeSetInnerHtml, convertTagToPlaintext, sanitizeHtml } from './domSanitize.js';",
      "146:     const sanitizerConfig = getDomSanitizerConfig(markdown, options.sanitizerConfig ?? {});",
      "147:     safeSetInnerHtml(renderedContent, renderedMarkdown, sanitizerConfig);",
      "222:             if (options.sanitizerConfig?.replaceWithPlaintext) {",
      "257:             if (options.sanitizerConfig?.remoteImageIsAllowed) {",
      "259:                 if (uri.scheme !== Schemas.file && uri.scheme !== Schemas.data && !options.sanitizerConfig.remoteImageIsAllowed(uri)) {",
      "313:         // Note: we always pass the output through dompurify after this so that we don't rely on",
      "316:             if (options.sanitizerConfig?.replaceWithPlaintext) {",
      "428: function sanitizeRenderedMarkdown(renderedMarkdown, originalMdStrConfig, options = {}) {",
      "429:     const sanitizerConfig = getDomSanitizerConfig(originalMdStrConfig, options);",
      "430:     return sanitizeHtml(renderedMarkdown, sanitizerConfig);",
      "509:         // Since we have our own sanitize function for marked, it's possible we missed some tag so let dompurify make sure.",
      "552:     return sanitizeRenderedMarkdown(html, { isTrusted: false }, {})"
    ]
  }
]
← All docsView source on GitHub →