MCPcopy Index your code
hub / github.com/darkreader/darkreader / escapeHTML

Function escapeHTML

tests/browser/coverage.js:65–72  ·  view source on GitHub ↗
(/** @type {string} */html)

Source from the content-addressed store, hash-verified

63}
64
65function escapeHTML(/** @type {string} */html) {
66 return html
67 .replace(/&/g, '&')
68 .replace(/</g, '&lt;')
69 .replace(/>/g, '&gt;')
70 .replace(/"/g, '&quot;')
71 .replace(/'/g, '&#039;');
72}
73
74/** @typedef {{name: string; length: number; coverage: number; parts: {text: string; covered: boolean}[]}} FileCoverageInfo */
75

Callers 1

Calls

no outgoing calls

Tested by

no test coverage detected