MCPcopy
hub / github.com/docsifyjs/docsify / escapeHtml

Function escapeHtml

src/plugins/search/search.js:24–34  ·  view source on GitHub ↗
(string)

Source from the content-addressed store, hash-verified

22}
23
24function escapeHtml(string) {
25 const entityMap = {
26 '&': '&',
27 '<': '&lt;',
28 '>': '&gt;',
29 '"': '&quot;',
30 "'": '&#39;',
31 };
32
33 return String(string).replace(/[&<>"']/g, s => entityMap[s]);
34}
35
36function getAllPaths(router) {
37 const paths = [];

Callers 2

genIndexFunction · 0.85
searchFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…