MCPcopy Create free account
hub / github.com/react-dnd/react-dnd / escapeCode

Function escapeCode

scripts/markdownLoader.js:48–55  ·  view source on GitHub ↗
(code)

Source from the content-addressed store, hash-verified

46};
47
48function escapeCode(code) {
49 return code
50 .replace(/&/g, '&')
51 .replace(/</g, '&lt;')
52 .replace(/>/g, '&gt;')
53 .replace(/"/g, '&quot;')
54 .replace(/'/g, '&#39;');
55}
56
57module.exports = function(markdown) {
58 if (this && this.cacheable) {

Callers 1

markdownLoader.jsFile · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected