(rel, href, crossOrigin)
| 17081 | } |
| 17082 | var globalDocument = "undefined" === typeof document ? null : document; |
| 17083 | function preconnectAs(rel, href, crossOrigin) { |
| 17084 | var ownerDocument = globalDocument; |
| 17085 | if (ownerDocument && "string" === typeof href && href) { |
| 17086 | var limitedEscapedHref = |
| 17087 | escapeSelectorAttributeValueInsideDoubleQuotes(href); |
| 17088 | limitedEscapedHref = |
| 17089 | 'link[rel="' + rel + '"][href="' + limitedEscapedHref + '"]'; |
| 17090 | "string" === typeof crossOrigin && |
| 17091 | (limitedEscapedHref += '[crossorigin="' + crossOrigin + '"]'); |
| 17092 | preconnectsSet.has(limitedEscapedHref) || |
| 17093 | (preconnectsSet.add(limitedEscapedHref), |
| 17094 | (rel = { rel: rel, crossOrigin: crossOrigin, href: href }), |
| 17095 | null === ownerDocument.querySelector(limitedEscapedHref) && |
| 17096 | ((href = ownerDocument.createElement("link")), |
| 17097 | setInitialProperties(href, "link", rel), |
| 17098 | markNodeAsHoistable(href), |
| 17099 | ownerDocument.head.appendChild(href))); |
| 17100 | } |
| 17101 | } |
| 17102 | function prefetchDNS(href) { |
| 17103 | previousDispatcher.D(href); |
| 17104 | preconnectAs("dns-prefetch", href, null); |
no test coverage detected
searching dependent graphs…