MCPcopy Create free account
hub / github.com/Epic0522/Codex-Remote-Contact / htmlToPlainText

Function htmlToPlainText

src/server.js:2373–2378  ·  view source on GitHub ↗
(html)

Source from the content-addressed store, hash-verified

2371}
2372
2373function htmlToPlainText(html) {
2374 return cleanHtml(String(html || "")
2375 .replace(/<script[\s\S]*?<\/script>/gi, " ")
2376 .replace(/<style[\s\S]*?<\/style>/gi, " ")
2377 .replace(/<noscript[\s\S]*?<\/noscript>/gi, " "));
2378}
2379
2380function parseDuckDuckGoResults(html) {
2381 return String(html || "")

Callers 1

fetchPageSnippetFunction · 0.85

Calls 1

cleanHtmlFunction · 0.85

Tested by

no test coverage detected