RegExp Literal Notation
Literal JS Syntax to create RegExp
, execute at Compile Time
const re = /pattern/flags;
References
.replace(/'/g, "\\'")
.replace(/"/g, '\\"')
.replace(/\n/g, "")
RegExp Literal Notation
Literal JS Syntax to create RegExp
, execute at Compile Time
const re = /pattern/flags;
.replace(/'/g, "\\'")
.replace(/"/g, '\\"')
.replace(/\n/g, "")