MCPcopy Index your code
hub / github.com/ampproject/amphtml / normalizeRCData_

Method normalizeRCData_

validator/js/engine/htmlparser.js:708–712  ·  view source on GitHub ↗

* Escape entities in RCDATA that can be escaped without changing the meaning. * @param {string} rcdata The RCDATA string we want to normalize. * @return {string} A normalized version of RCDATA. * @private

(rcdata)

Source from the content-addressed store, hash-verified

706 * @private
707 */
708 normalizeRCData_(rcdata) {
709 return rcdata.replace(LOOSE_AMP_RE_, '&$1')
710 .replace(LT_RE, '<')
711 .replace(GT_RE, '>');
712 }
713};
714exports.HtmlParser = HtmlParser;
715

Callers 1

parseMethod · 0.80

Calls 1

replaceMethod · 0.45

Tested by

no test coverage detected