MCPcopy Create free account
hub / github.com/idank/explainshell / __addSublanguage

Method __addSublanguage

explainshell/web/static/js/highlight.min.js:40–41  ·  view source on GitHub ↗
(e,t)

Source from the content-addressed store, hash-verified

38 a._collapse(e)})))}}class c extends a{constructor(e){super(),this.options=e}
39 addText(e){""!==e&&this.add(e)}startScope(e){this.openNode(e)}endScope(){
40 this.closeNode()}__addSublanguage(e,t){const n=e.root
41 ;t&&(n.scope="language:"+t),this.add(n)}toHTML(){
42 return new o(this,this.options).value()}finalize(){
43 return this.closeAllNodes(),!0}}function l(e){
44 return e?"string"==typeof e?e:e.source:null}function g(e){return h("(?=",e,")")}

Callers 1

gFunction · 0.80

Calls 1

addMethod · 0.80

Tested by

no test coverage detected