RegExp
constructor JS-01153639 });
3640 var ee = "popover",
3641 ne = i.default.fn[ee],
3642 ie = new RegExp("(^|\\s)bs-popover\\S+", "g"),3643 oe = a({}, te.Default, {
3644 placement: "right",
3645 trigger: "click",
3106 }
3107 var Yt = "tooltip",
3108 zt = i.default.fn[Yt],
3109 Xt = new RegExp("(^|\\s)bs-tooltip\\S+", "g"),3110 Kt = ["sanitize", "whiteList", "sanitizeFn"],
3111 Gt = {
3112 animation: "boolean",
2245 (It.Defaults = At);
2246 var Ot = "dropdown",
2247 xt = i.default.fn[Ot],
2248 jt = new RegExp("38|40|27"),2249 Lt = {
2250 offset: 0,
2251 flip: !0,
When a regular expression is known in advance, it is considered a best practice to avoid the string literal notation on top of the regular expression notation, and use regular expression literals instead of the constructor function.
// bad practice:
const number = new RegExp("^\d\.$");
// recommended:
const number_ = /^\d\.$/;
Regex literals are easier to read and do not require a call to the RegExp
constructor at runtime.
new RegExp("abc");
new RegExp("abc", "u");
RegExp("abc");
RegExp("abc", "u");
new RegExp("\d\d\.\d\d\.\d\d\d\d");
RegExp(`^\d\.$`);
new RegExp(String.raw`^\d\.$`);
/abc/;
/abc/u;
/\d\d\.\d\d\.\d\d\d\d/;
/^\d\.$/;
// RegExp constructor is allowed for dynamically generated regular expressions
new RegExp(pattern);
RegExp("abc", flags);
new RegExp(prefix + "abc");
RegExp(`${prefix}abc`);
new RegExp(String.raw`^\d\. ${sufix}`);