MCPcopy Create free account
hub / github.com/processing/p5.js / escapeRegExp

Function escapeRegExp

src/io/csv.js:209–211  ·  view source on GitHub ↗
(str)

Source from the content-addressed store, hash-verified

207}
208
209function escapeRegExp(str) {
210 return str.replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g, '\\$&');
211}

Callers 2

parseFunction · 0.85
stringifyFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected