MCPcopy Index your code
hub / github.com/idank/explainshell / w

Function w

explainshell/web/static/js/highlight.min.js:258–276  ·  view source on GitHub ↗
(e)

Source from the content-addressed store, hash-verified

256 ;if(e.language&&t.language){if(O(e.language).supersetOf===t.language)return 1
257 ;if(O(t.language).supersetOf===e.language)return-1}return 0})),[r,a]=o,c=r
258 ;return c.secondBest=a,c}function w(e){let t=null;const n=(e=>{
259 let t=e.className+" ";t+=e.parentNode?e.parentNode.className:""
260 ;const n=p.languageDetectRe.exec(t);if(n){const t=O(n[1])
261 ;return t||(X(a.replace("{}",n[1])),
262 X("Falling back to no-highlight mode for this block.",e)),t?n[1]:"no-highlight"}
263 return t.split(/\s+/).find((e=>b(e)||O(e)))})(e);if(b(n))return
264 ;if(N("before:highlightElement",{el:e,language:n
265 }),e.dataset.highlighted)return void console.log("Element previously highlighted. To highlight again, first unset `dataset.highlighted`.",e)
266 ;if(e.children.length>0&&(p.ignoreUnescapedHTML||(console.warn("One of your code blocks includes unescaped HTML. This is a potentially serious security risk."),
267 console.warn("https://github.com/highlightjs/highlight.js/wiki/security"),
268 console.warn("The element with unescaped HTML:"),
269 console.warn(e)),p.throwUnescapedHTML))throw new J("One of your code blocks includes unescaped HTML.",e.innerHTML)
270 ;t=e;const i=t.textContent,o=n?m(i,{language:n,ignoreIllegals:!0}):x(i)
271 ;e.innerHTML=o.value,e.dataset.highlighted="yes",((e,t,n)=>{const i=t&&s[t]||n
272 ;e.classList.add("hljs"),e.classList.add("language-"+i)
273 })(e,n,o.language),e.result={language:o.language,re:o.relevance,
274 relevance:o.relevance},o.secondBest&&(e.secondBest={
275 language:o.secondBest.language,relevance:o.secondBest.relevance
276 }),N("after:highlightElement",{el:e,result:o,text:i})}let y=!1;function _(){
277 "loading"!==document.readyState?document.querySelectorAll(p.cssSelector).forEach(w):y=!0
278 }function O(e){return e=(e||"").toLowerCase(),i[e]||i[s[e]]}
279 function v(e,{languageName:t}){"string"==typeof e&&(e=[e]),e.forEach((e=>{

Callers 1

teFunction · 0.70

Calls 8

bFunction · 0.85
addMethod · 0.80
OFunction · 0.70
XFunction · 0.70
NFunction · 0.70
mFunction · 0.70
xFunction · 0.70
execMethod · 0.45

Tested by

no test coverage detected