MCPcopy Create free account
hub / github.com/Consensys/doc.linea / getCompactText

Function getCompactText

scripts/agent-docs/lib.js:226–236  ·  view source on GitHub ↗
($, element)

Source from the content-addressed store, hash-verified

224
225 clone.find("script, style, button, svg").remove();
226 clone.find("br").replaceWith("\n");
227 clone
228 .find("p, div, li, tr, td, th, span, strong, em, code")
229 .each(function addWordBoundaries() {
230 $(this).prepend(" ");
231 $(this).append(" ");
232 });
233
234 return clone
235 .text()
236 .replace(/\u00a0/g, " ")
237 .replace(/\s+/g, " ")
238 .trim();
239}

Callers 1

prepareRedocForMarkdownFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected