MCPcopy
hub / github.com/websanova/js-url / escapeInnerText

Function escapeInnerText

lib/qunit/qunit.js:948–961  ·  view source on GitHub ↗
(s)

Source from the content-addressed store, hash-verified

946}
947
948function escapeInnerText(s) {
949 if (!s) {
950 return "";
951 }
952 s = s + "";
953 return s.replace(/[\&<>]/g, function(s) {
954 switch(s) {
955 case "&": return "&amp;";
956 case "<": return "&lt;";
957 case ">": return "&gt;";
958 default: return s;
959 }
960 });
961}
962
963function synchronize( callback, last ) {
964 config.queue.push( callback );

Callers 1

qunit.jsFile · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected